The xylem tissue in plants undergoes primary and secondary growth. During primary growth, the xylem forms protoxylem and metaxylem from the procambium.
Protoxylem matures before the plant organs have completed their elongation. In the stem, protoxylem is arranged towards the centre. In the root, it is arranged towards the periphery.
Metaxylem matures after the completion of growth of the plant organ. In stem, it is arranged towards the exterior. In root, it is arranged towards the interior.
This difference is due to the growth pattern in plants, roots forming first then the remaining parts of the plants such as the stem forming later.