Not all mange is contagious
Demodex as Iv4dogs just pointed out is an endemic mite that does not cause problems in normal dogs. Demodex comes up as a response of a suppressed or immature immune system. Outside of collies, oral Ivermectin over 3 months can bring the mite under control. In rare cases a genetic T-cell defect can cause the mites to create problems throughout the dog's life. Demodex in an adult geriatric dog indicates a serious immune problem (e.g. cancer).
In summary if the diagnosis was Demodex then it's not contagious and easily treatable (minus the genetic problem). If it's some other type of mange then it could be contagious. Ask the shelter for confirmation it's Demodex. Speculation here that given the stress of the shelter, it's Demodex.