Last time we were thinking about why some birds hop and other birds walk. We decided that you can't make any blanket statements about this, because there will always be exceptions. But due to the amount of energy required, it's generally true that larger birds are more likely to walk and smaller birds to hop.
But there's more to it than that. Ornithologists are actually very interested in bird legs and feet. The differences between various kinds of legs are used in bird classification. For example, what we commonly call "songbirds"--cardinals, wrens, mockingbirds, warblers--are also called "perching birds." They have specialized structures in their feet that include three toes pointing forward and one more called the "hallux" that points back. That three-and-one design is excellent for holding on to branches, which is an important skill to possess if you are a bird.
A bird with a conspicuous hallux toe won't be very good at walking. Some birds manage it, and there are different kinds of hallux toes that make it easier or harder. But to move around with feet like that, sometimes you just might be better off hopping.
So, evolution has to make a choice. Is it better to perch safely on branches or walk comfortably on the ground? Do I catch food with my feet or my beak? And so on. The end result can be birds with different kinds of feet, and different kinds of walks.