It is very easy to add password protection to your Mac’s screensaver.
First, open System Preferences. It is probably in your Dock, otherwise you can find it by clicking the apple in the upper left corner of your screen and selecting “System Preferences” from the list.
When System Preferences has launched, click the “Security” icon.
The “Security” preference pane will now appear. Now, simply check the box next to the text saying “Require password to wake this computer from sleep or screen saver”.
Now you are all done!