You’re correct, that code with new line containing tabs doesn’t work like that on GitHub
This however doesn’t apply if there was Markdown in-between after the first new line, here is an example:
<h1>
[*Italic Link*](https://example.com)
[*Another Italic Link*](https://example.com)
</h1>
Anyways, Obsidian doesn’t strictly follow GFM, here is an example