It’s a memory mapped file. If you update a bool or number value it’ll rewrite just that. If you update anything else it’ll often have to rewrite the entire document due to variable size.
But rewriting the document is more extensive, it might even have to be moved (because Mongo allocates certain number of bytes for it, and it might outgrow that).