It is derived from an old Aztec legend. The story tells that the leader of a nomadic tribe was visited by a god in his dreams that told him to build a city where they find an eagle eating a serpent perched on a cactus. This city is current-day Mexico City, the capital of Mexico.
Hope this helps!