District 9 was set in present day SA.
present-day South Africa, a generation after the aliens had arrived in 1982. That's the point. When the aliens arrived, apartheid was still fully in force, and the consequences of their arrival caused South Africa's history in the D9 universe to unfold differently than it did in our universe. In our reality, apartheid was overthrown (though much discrimination remains), while in the D9 universe, a new form of apartheid was imposed on the aliens and remained in force up to the present.
Like I said, it's about initial conditions. The D9 aliens arrived in 1982 South Africa, a place and time where racial segregation was normalized and institutionalized, and their arrival only reinforced those patterns. The Tenctonese arrived in 1990s California, a place and time where the society and its laws and institutions were attempting to eliminate and overcome the racial segregation of the past and cope with a society that was already a rich mixture of different ethnicities and cultures coexisting in the same community. Thus, the conditions upon the aliens' arrival made it harder for a policy of isolation and internment of immigrants to take permanent hold.
Of course, both works were social allegories. AN was an allegory for the immigrant experience in America and the turbulent racial politics of 1990s Southern California (remember, this was only a few years before the 1992 LA race riots). D9 was an allegory for the decades-long history of apartheid, and the legacy thereof that South Africa was still dealing with even decades after it had officially ended. So the treatment of the aliens in the respective works differs in the same way that the racial history of the two countries differs. It's not about one being more "believable" as if there's only one possible way for human beings to behave. They're both believable in the context of the different countries, eras, and cultures in which they take place, because they were both created to be reflections of the real-life racial issues in those cultures.