Application of the rietveld method to phase analysis of multilayered systems