"The main reason why severance is offered is to keep people from portraying the company in a bad light."
Probably a more important reason for offering severance is to insure against former employees suing the company (for wrongful dismissal, discrimination, sexual harassment, etc.). Most severance agreements demand a "general release of liability" in return for the severance payment. (Of course, that doesn't shield the company from criminal liability if anything they did was actually illegal, e.g., wage theft.)