I often play board games with friends that I do not particularly enjoy because they do enjoy it ... but there is a difference between putting someone else's preferences ahead of yours for a couple hours for a board game and putting your joy aside for 200 hours so that your friends can get what they want in an RPG.
The equivalent discussion can be had about relationships. If your significant other wants to watch a movie that doesn't appeal to you, it isn't unreasonable for them to ask you to watch it with them to keep them company. However, if they expect you to take up a hobby of theirs that you either dislike or find offensive ... and they expect you to do it week after week ... it is a different discussion.
If you're on these boards, you like are, or want to be, playing a lot of D&D. If you'd be happier playing Warhammer 40K, Gloomhaven, or something else, but your friends would not, consider whether it is time to look to expand your friend circle. D&D is often a huge time investment. If you're only kind of enjoying it, that is a huge investment into something not too great for you. Your friends may be wonderful people and hanging out with them may 'make up' for the deficiencies of the game ... but there are wonderful people out there in the world that enjoy your preferred hobbies.
And just to note it - many of the horror stories over the year about players ruining games are stories about people that do not care about the role playing ruining the fun of their friends that do because they have different priorities. This doesn't mean you are a problem - but it means you have something in common with a lot of players that are problems eventually.
As I said - I'm not kicking anyone out ... but if you do not enjoy role playing elements of D&D it is well worth your time to consider looking for ways to transition into hobbies where you are passionate about the best things in those hobbies.