I think there might be an error in the examples as the second example does not have a single root element.
If you need to spot an array vs an element, you have to use a container tag to express it. This is the same structure as is needed to encode algebraic data types.
element: <a>b0</a>
array of two elements: <array><a>b0</a><a>b1</a></array>
array of one element: <array><a>b0</a></array>