Cerberus was killed when Serapis turned him into his staff.
This would explain how Cerberus can exist as a separate character. He was killed when Serapis made his staff turning Cerberus's body into the staff, while Cerberus got sent to Tartarus to reform.- Cerberus is immortal.
Annabeth didn't have to stab the dog head.
Another possibility was stabbing whichever head represented the past. No past means no present, which means no future.