In fairness ID is pretty usless if your flights for the day all happen to be full of the annual John / Joanne Smith club outing...
If all check-in staff checked the Ref number against the mainfest this would not happen. Or checked they had correct ticket for the flight.
You can have 200 Mr John Doe's on the flight but they will all have different ref numbers.
Mistakes do happen.