Windows safe mode

How do you enter into windows safe mode. There have been some large amount of of defender notification about something trying to access my files and i would like to know how to isolate and remove it without any harm to my data

I believe that this is done by clicking on the restart option in the power menu while holding shift, then select troubleshoot > advanced options > change startup settings
Then the machine reboots and give you a menu, from memory option 5 is the one you want for safe mode but it should tell you which one to select.