The answer is yes. Gandhi spoke in favor of British colonialism, casteism, and white supremacy while promoting Indian liberation. At best he was a hypocrite, neither the first nor the last among activists to be true but certainly no role model for Afrikan liberation.
The issue is that he is romanticized, yet there are hundreds of other Afrikan philosophers, rulers, and activists who advocated similar philosophies. The rub he is not personally responsible for is the lionizing of his own image which like that of the rapist, child molester, and slaver Thomas Jefferson misleads oppressed people into thinking many of their own oppressors, liberators. Its the same Eurocentric revisionist historicism that turns murderers and thieves of the colonial US west into frontier pioneer heroes or the beast Cecil Rhodes into someone worth naming a prestigous scholarship after.
Gandhi is disposable for me because I don’t need him for liberation theorizing, knowing the depth and breadth of Afrikan history. The reason we glorify many figures is out of ignorance about them AND ignorance about others in our own traditions and histories that may have inspired and/or transcended them. The idea that Gandhi evented nonviolent resistance against colonialism is rubbish and the notion of democracy coexistent with cultural and racist casteism is as idiotic as the notion of democracy and slavery tried in the US.