Validity means:
In addition to well-formedness (conforming to the rules of XML as a metalanguage), there is also validity which requires conforming to the rules of a specific language, such as TEI or HTML.
These rules are very similar to the rules for speaking in a human language: am I using the right words? and am I using them in the correct manner?
When we check an XML document for validity, we are making sure that the document obeys the rules of a specific language.