Sir Ian McKellen has hit back at Damian Lewis after the Homeland star said he did not want to end up a "fruity actor" known for playing wizards.

McKellen, who reprises his role as Gandalf in the Hobbit sequel The Desolation of Smaug, said "no one needs to feel sorry for me" after Lewis alluded to his career as one of the reasons why he wanted to break out of the theatre.

Lewis, in a Guardian interview in October, said he worried in his 20s that he would be "one of these slightly over-the-top, fruity actors who would have an illustrious career on stage, but wouldn't start getting any kind of film work until I was 50 and then start playing wizards".

McKellen was forthright in his response but, like Lewis, declined to name names. "I wouldn't like to have been one of those actors who hit stardom quite early on and expected it to continue and was stuck doing scripts that I didn't particularly like just to keep the income up," he told the Radio Times.

"I've always wanted to get better as an actor. And I have got better. You've only got to see my early work to see that."

He added: "As for a fruity voice? Well, it may be a voice that is trained like an opera singer's voice: to fill a large space. It is unnatural.

"Actors have to be heard and their voice may therefore develop a sonorous quality that they can't quite get rid of, so you think actors are as pompous as their voice is large. I suppose Damian was thinking of that a little bit, too."

McKellen, who described Lewis's remarks as "fair comment", said: "No one needs to feel sorry for me or Michael Gambon [who played Professor Dumbledore in the Harry Potter movies] or anyone else who has fallen victim to success."

Currently starring in two plays on Broadway in New York, he admitted his performance in the ITV sitcom Vicious, in which he played one half of a gay couple opposite his good friend Derek Jacobi, was "over the top", saying he was acting too much for the live studio audience.

McKellen, 74, who came out in 1988, said he had sympathy for gay A-list stars who decide to keep their sexuality a secret. "It's true of A-lists all over the world – A-list priests, A-list politicians. What will other people think? Will people still vote for me? Will people come and see me act?" he said.

"They're warned by the people who surround them – agents and managers, who have a living to make and are worried that the actor will get pigeonholed.

"I don't think the audience gives a damn … You don't have to be straight to play Gandalf. Anyway, who says that Gandalf isn't gay? I loved it when JK Rowling said that Dumbledore was gay."

McKellen said he had been advised by the Foreign Office not to go to Russia because of its laws on homosexuality.

"They couldn't protect me from those laws. Two and a half hours from London! In the land of Tchaikovsky, Diaghilev, Rudolf Nureyev – gay artists whose sexuality informed their work," he said.

"Imagine trying to be a gay actor, a gay anything in modern Russia? Where to be positively oneself, to be affectionate in public with someone you love of the same gender, or to talk of that love in the hearing of anyone under 18, will put you prison?"