How can you set a property in a `Properties` object in Java?
You can simply use the `put()` method to set properties in a `Properties` object.
That's incorrect. While `put()` can be used, it's not the method typically recommended for `Properties`.
Can you explain why `setProperty()` is preferred over `put()` in the `Properties` class?