The best way to handle this situation is to use a setup of
form - processor - confirmation
Form - the page where the user enters data
Processor - has no output, but processes the response of the form. typically keeps data in session
Confirmation - some kind of "thank you" or "try again" type of page, based on information in the session. will keep track of errors that might exist.
No need to use some kind of unique identifier. Note that nothing can really stop a user from resubmitting a page multiple times, it'll still get processed no matter. You can attempt to catch this via sessions, where you do a check to see if they are supposed to be on this page or not.