The compounds with (parent), (underdoped), , 0.33, 0.53 (superconductors with , 27.6, 13.9 K, respectively), and , 0.77 (overdoped) have been investigated versus temperature using Mössbauer spectroscopy. Special attention was paid to regions of the spin-density wave (SDW) antiferromagnetic order, spin-nematic phase, and superconducting transition. The compound exhibits a reduced amplitude of SDW as compared to the parent compound and preserved universality class of two-dimensional magnetic planes with one-dimensional spins. The spin-nematic phase region for is characterized by an incoherent magnetic order. shows coexistence of a weak magnetic order and superconductivity due to the vicinity of the quantum critical point. The charge-density modulations in the and superconductors are perturbed near . Pronounced hump of the average quadrupole splitting across superconducting transition is observed for the system with . The phosphorus substitution increases the Debye temperature of the compound. Moreover, experimental electron charge densities at Fe nuclei in this material conclusively show that it should be recognized as a hole-doped system. The measured Mössbauer spectral shift and spectral area are not affected by transition to the superconducting state. This indicates that neither the average electron density at Fe nuclei nor the dynamical properties of the Fe sublattice in are sensitive to the superconducting transition. Theoretical calculations of hyperfine parameters determining the patterns of Mössbauer spectra of with , 0.31, 0.5, and 1.0 are performed within the framework of the density-functional theory. These simulations provide an insight into changes of the immediate neighborhood experienced by Fe atoms upon the P for As substitution as well as enable us to explore influence of P doping on the electron density, electric field gradient, and hyperfine field at Fe nuclei in the system.