### Godot version

4.0 (c1128e911ccd6f1e8c35646df804d894652a58f1)

### System information

Arch Linux

### Issue description

Read-only dictionaries can still have new keys added. The value for the new key isn't set (it is kept `null`).

This is caused by `Dictionary::operator[]` not checking if the key exists when it is read only mode. Accessing a key in the underlying HashMap will create if it does not exist. The actual value isn't set because it only returns a dummy reference.

### Steps to reproduce

Run the following snippet:

```gdscript
var dict = {}
dict.make_read_only()
prints("dict", dict) # {}
dict.foo = "hi"
prints("dict", dict) # { "foo": <null> }
```

### Minimal reproduction project

[DictReadOnlyAddKey.zip](https://github.com/godotengine/godot/files/10943387/DictReadOnlyAddKey.zip)

return _p->variant_map.size();
}
bool Dictionary::is_empty() const {
	return !_p->variant_map.size();
}
bool Dictionary::has(const Variant &p_key) const {
	return _p->variant_map.has(p_key);
}
bool Dictionary::has_all(const Array &p_keys) const {
	for (int i = 0; i < p_keys.size(); i++) {
		if (!has(p_keys[i])) {
			return false;
		}
	}
	return true;
}
Variant Dictionary::find_key(const Variant &p_value) const {
	for (const KeyValue<Variant, Variant> &E : _p->variant_map) {
		if (E.value == p_value) {
			return E.key;
		}
	}
	return Variant();
}
bool Dictionary::erase(const Variant &p_key) {
	ERR_FAIL_COND_V_MSG(_p->read_only, false, "Dictionary is in read-only state.");
	return _p->variant_map.erase(p_key);
}
bool Dictionary::operator==(const Dictionary &p_dictionary) const {