It was a stylistic choice by the director. In this interview with Stephen Lemons, Jean-Jacques Annaud makes it abundantly clear that as far as he's concerned, once you're immersed into the story, the accents are largely meaningless and may even detract from your enjoyment of the film. He also highlights some movie classics that followed the same path:
Some journalists have been critical of the fact that you shot the film in English, and that the main players, with the exception of Ed
Harris, are British and have British accents. What's your response to
that criticism?
Half of the market is an English-speaking market! If you give them actors who cannot speak English, it just doesn't play. And as a
Frenchman, I can only direct in French or English; I cannot direct in
Russian. There's no way you can do this movie in the Russian or
German. You have to go with the original version in English. After
that, you've got the choice of British, American or maybe Australian
actors. I remind people that movies are made in the language of their
audience. When Shakespeare did "Romeo and Juliet," he didn't do it in
Italian, or even using English speakers with Italian accents. This
applies as well to "Dr. Zhivago," which was set in Russia, but had
English actors. It takes about five or 10 minutes to accept it, but
once you're in the story, you forget that those people are English or
American.
and in this interview with Ed Harris in Entertainment Weekly:
”[Director] Jean-Jacques Annaud specifically asked me not to do a
German accent. A lot of times the German accent in war movies becomes
a cliché – a ‘Hogan’s Heroes’ kind of deal. But I worked with a
dialect coach and did a Middle Atlantic thing, a little more cultured
than I myself am. A little more refined, if you will. At least I
didn’t sound like I was from New Jersey.”