in android XML is used to design the user interface. these are located in the resources file.using xml usually separates your logic from presentation.
by making these separations you can easily focus on your logic and develop an appealing application. this reduces the time it will take to generate the interface using logic code.
XML provides a tree-like structure which will help the developers to make it easy to understand.