LONDON — “We all had big challenges in the accent department,” admitted Armie Hammer, when asked how hard he had to work to perfect his Russian accent as Soviet agent Illya Kuryakin in “The Man From U.N.C.L.E.” (opening Friday). “Fortunately, we had a terrific dialect coach on board.”

Each of the movie’s principals was playing a character native to a country other than their own.

“I’m an American playing a Russian. Henry [Cavill, who portrays Napoleon Solo in the film] is a Brit playing an American. Elizabeth Debicki is Australian and she has to be convincing as an Italian.

Alicia [Vikander] is Swedish and she has to deliver a good German accent. Of course, I’d say her job was the easiest. It’s not that hard for a Swede to play a German — at least when it comes to the accent,” said Hammer with a big laugh. “Of course, I’ll bet she’ll disagree with that!”

Yet, beyond the inflections, Hammer said he enjoyed making this film because it not only “put me in a Guy Ritchie film, and that was so wonderful,” but it also made him think a lot about the Cold War world of the ’60s.

“Just the idea of the Berlin Wall and people dying to escape that world [of communist East Germany] to get a taste of freedom is something we all should never forget,” said the actor.

However, he quickly stressed that is not the goal of “The Man From U.N.C.L.E.”

“This is pure entertainment fantasy,” said Hammer. “It’s a great thriller and action film, but with a tremendous amount of humor in it. I love how Henry and I were able to mix it up and have fun with those characters. Guy Ritchie enjoyed the ad lib aspects of a lot of scenes. That was fun to do.”