Unusual physicochemical properties of ionic liquids (ILs) open vistas for a variety of new applications. Herewith, we investigate the influence of microviscosity and nanostructuring of ILs on spin dynamics of the dissolved photoexcited molecules. We use two most common ILs [Bmim]PF6 and [Bmim]BF4 (with its close analogue [C10mim]BF4) as solvents and photoexcited Zn tetraphenylporphyrin (ZnTPP) as a probe. Time-resolved electron paramagnetic resonance (TR EPR) is employed to investigate spectra and kinetics of spin-polarized triplet ZnTPP in the temperature range 100-270 K. TR EPR data clearly indicate the presence of two microenvironments of ZnTPP in frozen ILs at 100-200 K, being manifested in different spectral shapes and different spin relaxation rates. For one of these microenvironments TR EPR data is quite similar to those obtained in common frozen organic solvents (toluene, glycerol, N-methyl-2-pyrrolidone). However, the second one favors the remarkably slow relaxation of spin polarization, being much longer than in the case of common solvents. Additional experiments using continuous wave EPR and stable nitroxide as a probe confirmed the formation of heterogeneities upon freezing of ILs and complemented TR EPR results. Thus, TR EPR of photoexcited triplets can be effectively used for probing heterogeneities and nanostructuring in frozen ILs. In addition, the increase of polarization lifetime in frozen ILs is an interesting finding that might allow investigation of short-lived intermediates inaccessible otherwise.