Due to the knowledge of the rotation period and the presence of a rather strong surface magnetic field, the sharp-lined young Herbig Ae star HD 101412 with a rotation period of 42 d has become one of the most well-studied targets among the Herbig Ae stars. High-resolution HARPS polarimetric spectra of HD 101412 were recently obtained on seven different epochs. Our study of the spectral variability over the part of the rotation cycle covered by HARPS observations reveals that the line profiles of the elements Mg, Si, Ca, Ti, Cr, Mn, Fe, and Sr are clearly variable while He exhibits variability that is opposite to the behaviour of the other elements studied. Since classical Ap stars usually show a relationship between the magnetic field geometry and the distribution of element spots, we used in our magnetic field measurements different line samples belonging to the three elements with the most numerous spectral lines, Ti, Cr, and Fe. Over the time interval covered by the available spectra, the longitudinal magnetic field changes sign from negative to positive polarity. The distribution of field values obtained using Ti, Cr, and Fe lines is, however, completely different compared to the magnetic field values determined in previous low-resolution FORS 2 measurements, where hydrogen Balmer lines are the main contributors to the magnetic field measurements, indicating the presence of concentration of the studied iron-peak elements in the region of the magnetic equator. Further, we discuss the potential role of contamination by the surrounding warm circumstellar matter in the appearance of Zeeman features obtained using Ti lines.