The Document Object Model is the data representation of objects that include the structure and content of a document on the web.
A web Page is a document that can be either displayed in browser or as HTML Source. In both cases, it is the same document but the DOM representation allows it to be manipulated/changed/updated.
So, When a web page is loaded, the browser creates a DOM of the page automatically.