Quite a few systems - ORMs, JEE
webapps, and so forth were configured and/or wired together originally via XML. There were no annotations.
This was a royal pain, since as Stephan pointed out, to fully define an object and its configuration, you had to edit 2 files at the same time and if you forgot to keep the one in sync with the other, you'd have to go back and debug it.
With Java 5, annotations were added, and the XML-based configurations were effectively deprecated. Now you only had to edit one file, not two.
But XML configuration isn't obsolete. Some options aren't closely tied enough to a class to make them eligible as annotations. Plus XML provides an override mechanism. The common/default configuration is in the annotation, but if you want to employ an alternative configuration, you can do it in XML, since XML overrides annotations. That way you don't have to touch source code, just the XML. XML is declarative, so it can be automatically validated in many cases. Plus you can't accidentally screw up program logic, because the XML contains no logic.