"H1" or "h1" is not "html header" and "tag to indicate a header in the text." They can be put anywhere.
There is an optional rule:
- H1 is the document title
- H2 is a section header
- H3 are headings of subsections
and so on...
Well, if I correctly understand the question.