In this thesis, I will present a new modeling framework adapted to study the multiphase interstellar medium (ISM), including and especially within low-metallicity galaxies. In such chemically unevolved environments, important changes of the gas heating and cooling mechanisms are expected, with an impact on the resulting spectral signatures. We intend to use those spectral signatures as probes of the physical conditions in low-metallicity dwarf galaxies, which may resemble the conditions expected in the early universe. To analyze the complex spectral signatures arising from the interstellar gas heated by stars and X-ray sources, we selected a photoionization and photodissociation code (Cloudy). While the geometry of such 1D models is simplis...