i guess gumball just overfed him until one 日 he grew legs. i don,t really know but they should have an episode where we can see darwin growing his legs.
The is just one episode that is スプリット, 分割 into two bits Because gumball was ADHA as 4 年 old. He was 与えられた Darwin when he was accidently flushed down the toilet. But when he was about to die on dry land gumballs 愛 for ホーム made him evolve into having lungs this is also the reason why Darwin has legs.