They usually set up a trust account then they can keep the cash after they retire.
John McCain became a congressman 30 years ago with nothing but a Navy retirement check of $1200 per month and now is worth 70 Million.
Al Gore had 10 million and gave half to the DNC and kept the rest
John Glen pocketed 10 Million back in 1980 and didn't pay out 5 million to several companies he owed debts to. The company that made the yard signs got taken for over a million and Glen gave the cash to his family.