I made a mistake on my 2021 taxes. I didn't enter the full RRSP contribution, only the amount I was claiming. How do I correct this?

In the first 60 days of 2022 I contributed $5000. I only claimed $2500 deduction for 2021 and only listed the $2500. As a result, I didn't have "excess still to claim". In the first 60 days of 2023 I contributed $2500, and claimed $2500 deduction, presumably from 2022 contribution. Now I want to claim the 2023 contribution, but because I didn't enter it into 2022 return, again I don't have excess. I believe I have to go back and amend 2021, but don't know how or where to do this.