I am just guessing here, but I think your PSW visa for only for that. If you intended to get married you should have applied for a fiance visa from the county you originate from after completing the 2 years PSW visa. Then you would have the visa to come back to the UK and get married. I am not sure ...