This isn't happening only with South Africa. There'll be politics in each and every country's cricket board. In countries like India there is politics, but they create reasons and give retirement ans at times keeps players on rest. From India we can see large number of players getting their names on teams like UAE, Malaysia, Singapore and so on. One such player of India making big records from another country is Muthiah Muralidaran.
I am surprised that you came up with the name of Muthiah Muralidaran. He is a pure-Sri Lankan cricketer with no connection to India. His ancestors migrated to Sri Lanka many hundreds of years back and you can't label such people as foreigners to that country. He can't be compared to players such as Eoin Morgan, Jofra Archer, Ben Stokes and Imran Tahir.
May be @Duzter is living hundred of years back and he is here through time machine so please don't mind this and enjoy your weekend.

LOL... You don't know how much Sri Lankans are proud of Muttiah Muralitharan. He was the legend who put Sri Lanka on the cricketing map. The greatest player Sri Lanka ever produced. If you talk against Muralitharan in Sri Lanka, then for sure you will not come out in good shape. When Ross Emerson and Darell Hair noballed him for chucking in 1995, the entire country came out in his support.
And after all this, if you say that Murali is an Indian, and not Sri Lankan, then the only advice I'd give to you is to stay away from any Sri Lankan citizen (for your own safety). Cricket was something that united different races and ethnicities of Sri Lanka, despite the civil war. And this is the same sport which divided (and continuing to divide) various races in South Africa. Two countries... two different outcomes.