We have analysed a sample of 18 RR Lyrae stars (17 fundamental-mode -RRaband one first overtone -RRc) and three Population II Cepheids (two BL Her stars and one W Vir star), for which high-resolution (R 30 000), high signal-to-noise (S/N 30) spectra were obtained with either SARG at the Telescopio Nazionale Galileo (La Palma, Spain) or UVES at the ESO Very Large Telescope (Paranal, Chile). Archival data were also analyzed for a few stars, sampling 3 phases for each star. We obtained atmospheric parameters (T eff , logg, v t , and [M/H]) and abundances of several iron-peak and α-elements (Fe, Cr, Ni, Mg, Ca, Si, and Ti) for different pulsational phases, obtaining [α/Fe] =+0.31±0.19 dex over the entire sample covering -2.2<[Fe/H]<-1.1 dex. We find that silicon is indeed extremely sensitive to the phase, as reported by previous authors, and cannot be reliably determined. Apart from this, metallicities and abundance ratios are consistently determined, regardless of the phase, within 0.10-0.15 dex, although caution should be used in the range 0 φ 0.15. Our results agree with literature determinations for both variable and non-variable field stars, obtained with very different methods, including low and high-resolution spectroscopy. W Vir and BL Her stars, at least in the sampled phases, appear indistinguishable from RRab from the spectroscopic analysis point of view. Our large sample, covering all pulsation phases, confirms that chemical abundances can be obtained for RR Lyrae with the classical EW-based technique and static model atmospheres, even rather close to the shock phases.