As far as I know there is only one film depicting the Russian intervention in Afghanistan. Directed by Fedor Bondarchuk, 9th Company (2005) features seven conscripts who opt to serve in Afghanistan as this means only a one-year tour of duty and then – assuming you are still alive – you can go home.
After several months’ rigorous and brutal training they are sent into Afghanistan. Early in 1988 they take part in Operation Magistral and have to defend Hill 3234, which comes under fierce attack from the Mujahideen. Eventually, of the seven comrades, only Oleg Lyuti (Artur Smolyaninov) is left. He launches himself into a one-man attack on the Mujahideen fighters as they approach the hill. Soviet helicopters appear and rescue him. He is told the war is over and the Soviets are pulling out.
Lyuti breaks down as he looks round at all his dead comrades. The final scene shows Soviet troops pulling out of the country. I can’t confirm this, but I have been told it is Vladimir Putin’s favourite film.