Amending for dependent 2023

I had already filled my return and it had been rejected. My Girlfriend and I were never married normally she is the one to claim our son. This year we agreed that I can claim him. I’m not sure what I should do in order properly correct this