Whilst these sort of questions would be considered illegal in many countries, the UK included there are certain instances whereby exceptions are made based on the organisation or sector e.g. jobs in certain government organisations etc.
At one point in my career I've had to undergo an extensive and invasive security screening process which included credit checking, drugs testing etc and a lengthy final interview whereby political viewpoints and my personal stance on various conflicts were discussed.
Whilst in this instance the responses were unlikely to have any serious consequences such as being reported to a security agency, it was entirely possible that what was perceived as a 'potential risk factor' would result in security clearance not being granted and therefore not being successful in getting the job.
I personally wouldn't try to make my answers suit the organisation, not out of a moral objection, but because since the January Revolution there has been an almost continual state of unrest with further protests and a coup d'état. Who's to say that the organisations views which you may align yourself to for the purposes of the interview won't be dramatically unpopular and compromise you later.
If at all possible to politely decline the question with something along the lines of 'I prefer not to discuss politics, however I can assure you that my personal viewpoints will not affect my ability to perform the role effectively'.
If it's not possible to avoid the question (as it wasn't for me when I was faced with it) then I see only a couple of options available;
- Try to find something within an organisation whereby politics isn't an issue (I understand from your OP that this may be challenging but if answering the question is causing you significant anxiety it may be worth exploring).
- Try to find a position within an organisation that suits your personal stance and therefore answering honestly won't cause you a problem.
- Answer with what you think they want to hear and hope it doesn't come back to bite you.
Either way your situation is not ideal in any way, best of luck!