Captain Walter Barrie, 41, an avid fan of the Ibrox club, was serving in Afghanistan with The Royal Scots Borderers, 1st Battalion The Royal Regiment of Scotland when he was shot in the Nad-e Ali district of Helmand province.
McCoist said: "On behalf of all the players, directors and management team at Rangers I would like pass on my sincere condolences to Captain Walter Barrie's family.
"I am sure there are no words of comfort that will ease their pain but everyone at the club is thinking about them at this difficult time."
The Ministry of Defence could not say whether the soldier responsible for the shooting was playing in the game between British soldiers and members of the Afghan National Army (ANA).
Mr Barrie, a married father with a 15-year-old son, Callum, was shot at close range and Afghan authorities said shots had been fired after a disagreement escalated.
The shooting was the latest in a series of attacks in which Afghan military or police officers have turned their weapons on British troops who are working alongside them.
Analysts believe it threatens to damage Nato plans to give control for security to the Afghan authorities by the middle of next year.
McCoist's Rangers players are expected to wear black armbands in memory of the soldier at their next Third Division match against East Stirling on Saturday.
The Ibrox club said that Mr Barrie from Lanark, South Lanarkshire, was a "huge" supporter who had helped to organise morale-boosting matches between troops in Helmand province.
"Having read the tributes to Walter by family, friends and fellow members of the armed services, it is clear he was held in the highest regard by all who knew him," said McCoist.
"I also know he was a massive Rangers fan and his loss is undoubtedly a loss that will be felt by the football club as well."