Nicola Sturgeon’s privacy should be restricted amid the “sad” end of her marriage to Peter Murrell, John Swinney has said.