BMW is considering opening a factory in Russia as the country's new-car sales recover after years of decline.