“There’s really no good explanation,” she says. “We think that simply it’s more comfortable,” says Hallager.
This seem to the simple answer for now, we need more research on it.
But in another study, New Zealand scientists observing flamingos and other wading birds found that water temperature didn’t seem to make a difference. Instead, they said, it appears that flamingos share a primitive feature also seen in whales and dolphins: the ability to shut down half the brain while sleeping. That keeps the underwater animals from drowning while asleep.
As flamingos go into this half-awake state, “the natural reflex may be for one leg to be lifted towards the body as if it were gently lowering the body onto the ground,” said the scientists, who further reported that the posture is likely an automatic response to getting drowsy. And, standing on one leg would keep them from falling over and drowning, because flamingos—unlike ducks, for instance—have a build that lets them easily stand on one leg without losing their balance or having to harshly angle their knee or ankle joints.
More at Smithsonianmag.com
This looks more promising theory and in my opinion could turn out to be the reason.