Retirement tax questions

In this situation you will probably get a corrected W-2.

The company will take back its contribution

and you will have to amend because you took a deduction on your own contribution returned to you.