Neutered cats can and do spray - but only tend to do it in boundary territory areas, and disputed territory areas. Usually as indoors is their core area and ownership of the space is not disputed by unfamiliar cats, they will not spray indoors - but certainly if outside the scent markers left by another cat in or near their territory can and does trigger spraying. A neutered male that sprays outdoors will not likely spray indoors in his core space, because there are no scent markers from strange cats to challenge. Stress can trigger spraying indoors - as stress to a cat means insecurity about their core territory, so suddenly under stress there is the need to leave strong scent markers as territorial reassurance.
Entire cats spray more and much more likely to do it in their core territory indoors, because they are more territorial, and more likely to see small things as a challenge to their dominance of an area - neutering does not reduce the ability to spray, but reduces the territorial/dominant nature so makes spraying indoors far less likely. A neutered cat is generally less stressed about territorial matters than an entire tom, and that is what causes the difference in spraying behaviour.