A morgue is an area on a starship, starbase or other vessel or facility where officials store the physical remains of the recently deceased for identification, autopsy and other post mortem activities.
These storage areas sometimes use 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")
PumwI'-class and Khin'Vagh-class (and presumably, Negh'Var-class and QeylIS BetleH-class) starships were equipped with a starbase-grade morgue (by 24th century Klingon standards) in that they could hold hundreds of corpses in a single area. (RIS Bouteina: "Eidolon"; Star Trek: The Stoneship Files: "Attack on the Laboratory")
The morgues aboard Stoneship-class starships could handle 250 corpses at once; Vor'cha-class starships, like Klingon and Lyran dreadnoughts, had a morgue equipped with an autopsy station. (Star Trek: The Stoneship Files: "Ancient Horrors")
Caspian-class runabouts were not equipped with morgues. When False Vacuum Squadron found a murdered body, it had to ferry it to the closest Starfleet morgue for autopsy. (Star Trek: False Vacuum: "Arthur Porter and the Corpse of Azkapanama")