The Chinese certainly regarded the Mongols as Yi (until they became the Yuan Dynasty).
The chief problem with the Wall is that most of it is in the mountains. Since the purpose of a wall is to stop vehicles and horses, a purpose the mountains are already serving...
A symbol of the emperor's pride is indeed another theory. But several Chinese religions believe that spirits can't go over walls, hence the theory that it had religious significance to keep out evil spirits. I doubt it was simply to give jobs to idle hands. When you're a peasant, your hands are rarely idle, and if they were the emperor could surely have found them more practical employment than a wall in the mountains...
Most of the
surviving Wall is in the mountains, because that was the late ('Ming') wall made of stone. The bulk of the wall was across the plains/steppes/desert of central northern China, largely flat land, and the wall was made of the traditional Chinese fortification material, Rammed Earth. Which, if not maintained, becomes the Great Linear Lump and essentially disappears, which is what has happened.
The real value of the wall was not in
stopping nomads, but in forcing them to fight on Chinese Infantry Army terms. China's basic military problem was always that she had no good source of horses for cavalry except to buy them from the nomads that they needed the horses to fight against, and a foot-marching army in which about half the troops were 'bearers' to supply the other half (estimate from figures of the Tang Dynasty armies) was never going to catch, let alone beat or deter, the nomadic cavalry.
A well-garrisoned wall (and 'well garrisoned' was the
catch) reduced the value of nomadic mobility and forced them to fight essentially a head-on battle against Chinese infantry and missile troops who had the advantage off fortifications. BUT the wall only worked if it had substantial garrisons and some 'field' troops behind it to stop any nomads that did get across or around the wall, by catching them between the army and the wall - again, negating the nomads mobility.
When a Dynasty had the military might to effectively garrison the wall it worked, but that didn't happen consistently and when the garrisons left, the nomads came thundering back. Ironically, some of the most successful Dynasties (Tang, for example) were Mixed - the Tang aristocracy was a combination of Chinese, Nomadic, and mixed Chinese-Foreign, and so included a lot of horsemen and horse-breeders (who, as a result, converted a lot of farmland into pasturage and forcibly removed a lot of peasants and a lot of peasant food, which came back in the form of Peasant Revolts later) so that the Tang had armies of heavy and light cavalry every bit as good as the nomads'. But that was an exception: more often the nomads conquered the whole State (temporarily) so that numerous 'nomad' Dynasties dot the history of northern China. . .