In Ref. [Katz et al., arXiv:2007.08770 (2020], we present a mechanism and optimal procedures for mapping the quantum state of photons onto an optically inaccessible macroscopic state of noble-gas spins, which functions as a quantum memory. Here we introduce and analyze a detailed model of the memory operation. We derive the equations of motion for storage and retrieval of non-classical light and design optimal control strategies. The detailed model accounts for quantum noise and for thermal atomic motion, including the effects of optical mode structure and imperfect anti-relaxation wall coating. We conclude with proposals of practical experimental configurations of the memory, with lifetimes ranging from seconds to hours.