You buy it. Head to the Chao Kindergarten and look on the left-hand side for the shop.
The stock rotates, so what is available changes over time, but yellow eggs are among the more common ones and turn up fairly often. Check back if it is not there on your first visit.