Not really an immigration question. You may be better off asking that question in a forum dedicated to divorce proceedings or
consulting your local Citizen Advice Bureau.
Generally, if the marriage is recognised in the UK AND at least one partner is domiciled in the UK, then you can get divorced in the UK. However, there are differences in rules and procedure between Scotland, Northern Ireland and England & Wales in this matter. So, best to check with your CAB, as advised above.
I am not a lawyer or immigration advisor. My statements/comments do not constitute legal advice. E&OE. Please do not PM me for advice.