This is a pun on 'kidding' which in this context means the boy was joking about wanting to raise goats, but it's also used because 'kidding' is the term used for when goats give birth
A boy told his parents he wanted to raise goats for a living , but he was only kidding .