Is being an extrovert a necessary condition to be a manager?
Not a necessary condition, but a useful skill. You have other skills, so use them on the job.
BTW, you don't explain what is your managerial role (in what industry) and you don't explain why did you accept that role, and how important is to you to climb the hierarchical ladder, that it to become a manager at a higher level.
In my opinion and work experience, good managers are extremely rare (simply because the human brain is not suited for management).
In your list of desired skills relevant to management, you forgot quite an important one: emotional intelligence (which is something you can slightly improve, e.g. by reading books), in particular empathy and the ability to understand, ethically and with respect, the motivations and behavior of your subordinates (they are human beings just like you, not just homo economicus, see also this) and even of your superiors. These skills are not about leadership (even if they are related). And you can apply these skills not only to your subordinates, but even to your superiors. In simpler words, try hard to put yourself in other's shoes.
You probably cannot change the fact that you are more introvert than extravert, since that is part of your core personality (you could try many decades of psychotherapy, but is that worth the pain and the efforts?).
I’ve now got the feedback from my bosses that I’m too reserved and introverted to be in a leadership position.
Notice the confusion they are putting (very probably on purpose) in your mind. A manager is not a leader (even if corporate bullshit tells us otherwise every working day). A manager is someone organizing and facilitating team work (that manager word comes from the French ménage = housekeeping: l'homme de ménage -literally the manager man- is the janitor). In many software development corporations, the technical leader of some team is not its manager.
That might mean one of two things:
your boss is giving you the signal that you won't climb the management ladder anymore in your corporation. But do you really care that much? You still could be a good enough manager for years, and give enough satisfaction to both you and your corporation (team and superiors).
your boss is trying to convey to you that you did something else very wrongly, and the context in which he told you that is important.
To say it another way: don't try to be a perfect manager, just try to be a good enough one. You could be a good enough manager because of your other skills!
And that is excessively difficult. As I commented, most of the present and past managers I had were quite bad, from my (subordinate's) persepective. But they kept that job for many years.
Remember the obvious: in any kind of hierarchical organization, most of it members won't end at its top (related to the pigeonhole principle). Don't dream too much of become a CEO or reach the top level of management. But you still can be very valuable (to your corporation) and happy (for yourself) while staying at the same position for years.
To what extent is that a problem when it comes to leadership roles?
Being introvert is never a problem per se, but a fact of life (orthogonal to any managerial role). No more than wearing eyeglasses, or being a male or a female, or loving classical Russian opera music. There are good managers with eyeglasses, bad managers with eyeglasses, and good managers without eyeglasses or bad managers without eyeglasses. Likewise, there are good introvert managers, bad introvert managers, good extrovert managers, and bad extrovert managers.
You don't need to become extrovert (because you probably cannot), but you do need to become wiser about your job and your expectations from it. You probably need to accept the fact that you won't become a CEO (on the other hand, in the realm of large corporations, most top CEOs are psychotic! Do you want to be that? Do you even dream to become a Steve Jobs? I never did!)
In a comment, you also say:
I only feel bad about my bosses hating my style.
but the fact that they are telling you that could be their management strategy. I am not sure it is a good one. Even your own boss is likely to be a "bad" manager (because good managers are extremely rare).
So it is likely that the only problem is your perception of the situation, not the situation itself. From what you are telling us, it seems good. The probability that in a large corporation (of say more than 1000 people) every management layer is good enough is extremely small. Consider such a situation as improbable as your city being nuked tomorrow.
NB. This other answer of mine to another question is somehow related to my answer here.
PS. I am a research engineer, close to retirement, and grand-father. So I did have lots of managers. But I did actively refuse to even become one (or even to get any managerial role), and that decision I never regretted: in my personal system of values, becoming a manager is a shame (from my perspective, they are mostly liars), not a promotion. My manager is no more qualified than I am (we both have PhD in CS) and is as young as my oldest son, he don't looks a lot happier than me on the job, and he just earns perhaps 10 or 20% more than I do (and perhaps just as much as me).