Browsers have to have a default rendering of some kind (author stylesheets didn't exist when HTML was first introduced and are still an optional extra today).
If there was no margin/padding on the body/html then the text would run up against the window border and toolbar where it would be very hard to read (which would be a poor choice for a default rendering).
why would all browsers insert the very specific 8px margin on all webpages
"But it looks different in Netscape" was a common complaint. Browsers copied the default rendering from each other to compensate for authors writing pages and only thinking about one browser.
where every website removes it in the first few lines of CSS
Not every website does. It's a common (but not universal) practise for sites which are going to include a stylesheet, but not all sites do.