Flags are changes sometimes. Usually, it's because of a change of perception about the represent subject. I'll talk about it using the People's Republic of China (mainland China, not Taiwan) as example.
I'll take, as starting point to my explanation, the flag of China used between 1890 and 1911:
At the time, China was ruled by the Qing Dynasty (of Manchu ethnicity). Yellow was traditionally the imperial color of China, and the imperial family was the only that could use that color on clothes and buildings. The dragon has a well-known symbolism in Chinese culture, and the five-clawed one, like in the flag, was associated with the emperor. The red disc on the superior left is a flaming pearl, common on depictions of the Chinese dragon. It's someway related to the "Eight Banners" adopted by Manchu military organization.
In 1911, the China became a republic, after the Wuchan Uprising, and the flag was de facto replaced by the flag used by the rebels:
The eighteen disc represent the then eighteen provinces of China. There's a variant of this flag with a nineteenth star on the center of the star.
In 1912, a new flag was formally adopted; the Wuchan Uprising flag was kept as the Army flag until 1928. See it:
This flags was highly related with the new ideology of the Chinese policy, known as "Five Races Under One Union". Although the flag was intended to show certain harmony between the five races, they were placed in a order that shows a kind of ranking on Chinese society: red for the Han (the most numerous ethnicity on China), yellow for Manchu (notice the reference to first flag on post), blue for Mongols, white for the Hui (Muslims on China) and black for Tibetans.
The five-colored flag was used until 1928, with the exception of a brief period between 1915 and 1916, when occurred an attempt to restore the Chinese Empire. Two flag variants were used on that period:
The colors have the same symbolism, but now the Han ethnicity (represented by red color) takes a much more salient position on the flag.
In 1928, a new flag was adopted:
The flag replacement is again resulted by a radical change on policy. Between 1916 and 1918, in an event known as Northern Expedition, Chinese nationalists fought for the "reunification" of China through the disestablishment of local warlords. Red represent the blood of the martyrs that fought against Qing dynasty; the twelve-rays white sun on blue background represents the progress, symbolized by the twelve months and the twelve traditional Chinese hours (the shíchen), and was used as the symbol of Kuomintang party.
In 1949, with the result of Chinese Civil War, the troops of Chiang Kai-Shek were relocated to Taiwan islands and established the Republic of China (ROC), that still uses the 1928 flag, while the communists, led by Mao Zedong, established the People's Republic of China and adopted a new flag, still in use:
I don't need to explain that the red prominence is related to communism, do I? Also, there are five yellow stars, whose color may refer to the "yellow race" of the Chinese. The biggest star represents the Communist Part of China (CPC), representing the great "savior" of China. The four smaller stars represent the four constituent parts of the Chinese society: the rural workers, the proletariat, the urban petit bourgeoisie and the national bourgeoisie (whose representation on flag was controversial at the time). There's an alternate interpretation, probably dubious, that says the bigger star is for the Han ethnicity while the other stars represent the other four "races" of 1912-1928 flag.
So the Chinese flag changed from imperial to republican, then to representative, so then to nationalist and now to communist. Flags changed for ideological purposes, because they were all pretty cool, aesthetically and vexillologically.
Hope you liked the historical tour. Feel free to comment!