You implicitly form a tree structure, using a primitive representation, such as a String.
Replace your primitive representation with a Composite.