Browsing Godot's source code gives you the answer. It isn't very clear at first, but setting the value to null
erases the key.
From godot/object.cpp:L1048 (blob from the 3.1 branch):
if (p_value.get_type() == Variant::NIL) {
metadata.erase(p_name);
return;
};
EDIT Switched the blob to the 3.1 branch for accuracy.