Even that whole charade was completely misrepresented to sell it to the American public. There was no Soviet “invasion” of Afghanistan any more than there was an American invasion of South Vietnam; the Afghan GOVERNMENT asked the Soviets for help (as Saigon did with us years before), and the government they were supporting lasted for years after the USSR collapsed (I believe it fell in 1996 - it lasted longer than South Vietnam did after our withdrawal).
Like Americans today, the Soviet troops worked in collaboration with the official Afghan army (though they were allowed to shoot back).
I have read the accounts of Soviet soldiers in Afghanistan. There is a book called “The Forgotten War”. I read it in the 90’s and remember thinking “We armed a bunch of people who will kill us!”