These storage areas sometimes used stasis fields to preserve the bodies against further decay.
Aboard the USS Cantabrian, the morgue was located on deck 4 with other medical facilities, including sickbay. In 2372, Nelson worked part or all of his shift in the morgue. In the same year, a Myhr'an clone found aboard a Myhr'an scout ship was transported to the morgue for autopsy in the morning. Initially unknown to the crew, it was still alive and escaped stasis, taking on Nelson's form before murdering him. (Star Trek: The Cantabrian Expeditions: "Catalyst, Part One")