put

fun put(key: String, value: NBT): NBT?

Associates the specified value with the specified key in the compound.