The process by which a planetary body (a solid planet or major satellite) acquires a layered structure with dense materials at its center, in a core, and less dense materials in an overlying mantle and crust. A body that has formed by accretion has a homogeneous composition, with materials of different densities distributed uniformly throughout its volume