Given his background wasn't entirely peaceful this might be a bit surprising.
However while he was in prison he became very much a figurehead for those who supported attempts to do away with the racist apartheid regieme that was ruling South Africa.
However what really set the seal on his reputation was what he achieved after his release.
Normally when countries win their independence there are bloody civil wars as people struggle for Power.
It happened in India and Pakistan, In Ireland more died in the Civil war than the Troubles and Palestine/Israel goes without saying.
Nelson Mandela supported systems of reconcilliation that managed to achieve a peaceful form of power transition and did what many people thought impossible which was to achieve a transition of power to a true democracy without a violent civil war