I'm sure most of us have written characters we would not agree with. I'm hoping we could share those experiences here and how you really get into the mind of someone who is very different from you. Anything would be good, I just want us to discuss writing characters with different beliefs from us in general.
However, if we were to go more in depth, then in particular, I feel it can be difficult to write that character when specifically those beliefs and opinions you disagree with are being challenged. From your own point of view, changing those views are very logical, but of course people are very staunch in their views and they do have reason to the opinions they hold.
One of the stories I'm playing around with in my mind has a person without real roots who ended up settling in a place with strong nationalistic sentiments. An empire with overwhelming might seeks to conquer this nation, and the main character does not have a lot of problems accepting this empire, but of course, the new friends he has made would not agree and would fight against great odds in part because of their patriotic pride. This is the part where the main character tries to challenge their intents for a futile gesture of pride. I, myself, believe that nationalism is an outdated concept, while I can sort of get the sentiments behind it, they evaporate before my general pragmatist beliefs. So there is some difficulty in creating believable conflict here that isn't either people giving in easily to the MC's arguments or exaggerated bullheadedness against the MC's arguments. I wonder if anyone else has written something in a similar vein.
Anyway, as I said earlier, even if you don't have input on my particular example, I would like to see people share their personal experiences writing any characters who have very different beliefs from the writer.