The peculiarities of the partial isovalent substitution of calcium atoms by magnesium in the structure of -Са3(РО4)2 within the compositions of Ca10.5–хMgx(PO4)7 (х=0.4, 0.8, 1.0 and 1.5) were investigated by methods of chemical precipitation in aqueous solutions and solid-state interaction. In the first case, the biphasic calcium phosphates (based on Са10(РО4)6(ОН)2 and -Са3(РО4)2) doped with magnesium cations as well as monophasic Ca9.5Mg(PO4)7 and Ca9Mg1.5(PO4)7 (whitlockite-related, trigonal system, space group R-3c) were prepared as a result of mixing aqueous solutions at molar ratios Ca2+:Mg2+:PO43–=(10.5–x):x:7 (where x=0.4, 0.8, 1.0 and 1.5), with further evaporation of water and heating of the solid residue at a temperature of 6000С (for 2 hours). The biphasic calcium phosphates were also obtained by the solid-state interaction of initial components at the temperature range of 500–7000С (for 6 hours) and the same molar ratios Ca2+:Mg2+:PО43–=(10.5–х):х:7 (х=0.4, 0.8, 1.0 and 1.5). It was found that only the apatite-type phase (Са10(РО4)6(ОН)2) contains magnesium, and the content of this phase in the biphasic composites increases with the growing of magnesium amount in the initial mixtures. The established conditions of the formation of single phasic whitlockite-related magnesium-containing calcium phosphates as well as biphasic composites of modified calcium phosphates can be used in the future to obtain bioactive materials for medical purposes.