if available, the schema (XSD) should be used to create DocType and for the validation later on as this is the single point of truth in this case.
When there is only a DocType availabe (probably created manully) its constraints definition might be complete or can be changed easily without taking care of the data content at the same time.
When using the XSD it is neccessary to drop and recreate the DocType and Schema node when the constraints or the structure are changing.