There is a myth among a lot of smart people that they are held back precisely because they are so smart and so good at what they do; the decision makers are threatened by them and their skills, and don't want them to succeed. I see this in high school: "my teachers don't like me because I am smarter than them", for example. These people are smart, but not wise, and they're wrong.
As someone who was smarter than my teachers, who raised kids who were smarter than their teachers, who has been the smartest in the room too many times, keeps changing rooms, and still is often the smartest in the new room, let me tell you what they are reacting to that you perceive as "being a threat". It's not just that you're smarter than them. It's that, rightly or wrongly, you are sure you are smarter than them, and that the things you happen to know about are the only things that are relevant. If you've learned one way to do thing X, you are sure of the answer to "how do you X?" You don't know there are 4 other ways, or the circumstances under which the slower or more expensive way is actually better.
You know what you know, but you don't know what you don't know. Pretending to know less so as not to be "a threat" will not help. Becoming aware of what you don't know and thus phrasing your answers differently might help. So consider this.
How do you X?
I simply Y. I'm very good at it. I've done it a lot.
That's a pretty good answer. It's better than
I don't know, I never did that.
But how about:
In my experience so far, we've always Y. It's worked well and I'm good at it. I have heard some people A or B, and I would be interested in learning more about those.
or
Sometimes I Y, and sometimes I Z. I generally prefer Y because it's quicker [or more secure or easier to maintain.]
A little more self awareness. A little more acknowledgment that other people know things too. A little more acknowledgement that there's more than one way to do things, and sometimes you choose the quickest, sometimes the cheapest, sometimes the one that works out best in the long run. A little less knowing (instant answer) and a little more thinking (ask about factors that may be relevant but weren't in the question.)
This is hard work. But if you find your current attitude is causing a problem, I recommend that's what you do.