They already did that. It was called WebSQL. It was removed I think in favor of IndexedDB.
Mozilla again.. The real joke is, Firefox is now the only(?) browser using sqlite out-of-the-box for internal databases.
They could have used an actual KV store behind it, like chromium did (levelDB IIRC).