Because align='center' comes from the early days of HTML before CSS was invented. It was realized 20 years ago that this was a really bad idea, so those HTML attributes were deprecated in the early days of the web. It’s just that there’s an ethos that most HTML and CSS remains backwards compatible, which means browsers still support it.
It would be the equivalent of major freeways providing watering toughs for horses, just in case anyone still wants to travel by horse and cart. It’s really that out of date.
The table attributes, align and valign, were deprecated years ago. It looks like CodePen and jsfiddle have stopped supporting them whereas blogspot still supports them.
Ah, when you talk about “centering”, people tend to assume you’re talking about left/right (“horizontal”) centering. Vertical (up/down) centering is a bugger with HTML/CSS, and is kind of a holy grail. One modern method is to use display: flex, though it’s not fully supported yet. You can apply it to the body element, but I’m a little wary of that, so I prefer to use a container.