To protect their national language and heritage.
Language is a key part of culture, and in an increasingly globalized world, countries will seek to preserve their national language to prevent it from being lost. According to the Linguistic Society of America, there are over 5,000 spoken languages in the world today, but many of those languages are considered "endangered," meaning they may be lost in favor of the more commonly spoken languages in the world.
Incidentally, China is an interesting example. Though the Chinese government made standard Mandarin the official language of the country in 1956, there are over 50 ethnic groups and nearly 300 language dialects present in expansive territories of China. The Uyghur language is spoken by about 11 million people in China, for instance. Hmong language is spoken by nearly 3 million people worldwide, most of whom are in China. So while China has an official policy endorsing the Mandarin language, there are also many, many other language groups trying to preserve their own culture and heritage within China.