It looks like a growth defect, it may not be infected yet but could do easily, especially if the fish is in overstocked conditions.
Have you read up on the size requirents of aquariums and ponds for godfish and koi carp? Forgive me for asking if you have, but this is your fist post,
IME, goldfish (and other large cypinids like tench and orfe) very commonly attain such growths after being in too small a volume of water for months/years along with stunted growth.
Looking at that goldfish, it has a irregular and stunted body-shape unfortunately, and the koi carp in view behind it isn't a good sign (goldfish and koi are both unstable species for most aquariums, especially the koi).
Can you post water stats?

Ammonia, nitrite, nitrate and pH are especially important, preferably from a liquid test-kit rather than innacurate test-strips

.