DOM is the Document Object Model. It is an object-based representation of the source HTML document.
When the browser processes your HTML page, it creates a tree of tag objects. Each tag object represents one HTML tag.
The tag object contains all information about the tag - what is the tag name, what are the tag attributes, what is the content of the tag, what is the parent tag of the tag.
Except this, the tag object also has a reference to the parent tag object and all child tag objects. So that the tag objects are linked together and form a tree.
This tree can then easily be navigated. Thanks to it you can quickly find information about specific tag and its element and you can also change their properties.