_id is automatically generated by mongodb if you do not set it, or you can directly give a value, but as for the renaming mentioned by lz, it seems that it is not possible.
Renaming is not possible. If you really want to change the _id, you can try to create a new data and specify the _id, then copy the original data and delete the original data.
_id is the primary key of mongodb and cannot be renamed.
_id is automatically generated by mongodb if you do not set it, or you can directly give a value, but as for the renaming mentioned by lz, it seems that it is not possible.
Renaming is not possible. If you really want to change the _id, you can try to create a new data and specify the _id, then copy the original data and delete the original data.