Pain and urge while passing urine usually indicates urine infection. It is unlikely due to the result of hydrocoele surgery. Pain of hydrocoele surgery is more likely to be dull and persistent, getting exacerbated at movements, rather than with the act of voiding. It is quite common to see urinary infections and urinary retention following lower abdominal surgery in elderly. Basic cause, of course, is the prostate. He already had his prostate troubling him, as is evident from his previous intake of Urimax. High PSA may also indicate previously existing chronic prostate infection, and getting exacerbated during current surgery. It may however still be related to surgery as your father may have been catheterised during, or after, surgery.
It would be advisable to have urine examination and process the urine for bacterial culture, after a proper physical examination. An ultrasound for KUB region should also be done to look at the prostate, and exclude any significant residual urine. Medical treatment with a combination of an alpha blocker (like Urimax he was taking earlier) and a urinary antiseptic may be started by your physician awaiting the urine reports.
His PSA needs to be repeated after proper antibiotic therapy. If still found elevated, it indicates a risk of existing cancer in the prostate gland, and needs further evaluation.