How To Save My Level State In A File

Hi Guys,
I’m facing a issue regarding how to save properties of objects in my level, save it to a file for future opening and get the same position it was previously defined.
Example: My character moves a rock inside the level. I need to save the position of this rock and when the player opens the game the rock should be loaded in the position it was previously saved.

Please,
help me regarding this question.

Thanks you!!