Epitaxial layers of CoFeB were grown on MgO by means of laser molecular beam epitaxy using $\mathrm{C}{\mathrm{o}}_{40}\mathrm{F}{\mathrm{e}}_{40}{\mathrm{B}}_{20}$ target. The growth was combined with in situ structural characterization by three-dimensional reciprocal space mapping obtained from reflection high energy electron diffraction (RHEED) data. High-temperature single stage growth regime was adopted to fabricate CoFeB layers. As confirmed by the atomic force microscopy, the surface of CoFeB layers consists of closely spaced nanometer sized islands with dimensions dependent on the growth temperature. As shown by RHEED and XRD analysis, the CoFeB layers grown at high-temperature on MgO(001) possess body centered cubic (bcc) crystal structure with the lattice constant $a=2.87\phantom{\rule{0.16em}{0ex}}\AA{}$ close to that of the $\mathrm{C}{\mathrm{o}}_{75}\mathrm{F}{\mathrm{e}}_{25}$ alloy. It was further shown that following the same high-temperature growth technique the MgO/CoFeB/MgO(001) heterostructures can be fabricated with top and bottom MgO layers of the same crystallographic orientation. The CoFeB layers were also grown on the GaN(0001) substrates using MgO(111) as a buffer layer. In this case, the CoFeB layers crystallize in bcc crystal structure with the (111) axis perpendicular to the substrate surface. The magnetic properties of the CoFeB/MgO (001) heterostructures have been investigated by measuring magnetization curves with a vibrating sample magnetometer as well as by performing magneto-optical Kerr effect (MOKE) and ferromagnetic resonance (FMR) studies. FMR spectra were obtained for the variety of the magnetic field directions and typically consisted of a single relatively narrow resonance line. The magnetization orientations and the resonance conditions were calculated in the framework of a standard magnetic energy minimization procedure involving a single ${K}_{1\mathrm{c}}$ cubic term for the magnetocrystalline anisotropy. This allows a fairly accurate description of the angular dependences of the resonance fields---both in-plane and out-of-plane. It was shown that CoFeB layers exhibit in-plane fourth-order magnetic anisotropy. A two-step magnetization reversal model has been adopted for the CoFeB layers based on the VSM measurement analysis. Magnetization reversal studies performed by polar MOKE indicate that the magnetization lies in-plane in absence of magnetic field. Observed magnetic field dependences of reflected light ellipticity in geometry of longitudinal Kerr effect give convincing evidence for contribution of quadratic in magnetization terms in the dielectric tensor and clearly show the in-plane magnetization rotation.