Block bad referers

When you type the address of a site in the address bar of the browser, there is no referer, it's a direct access.

The referer is the site from which you arrive. If you make a request in a search engine, for example on Google, by clicking on a link in the results, the referer will be "google.com".
If my site has a link from a malicious site, then I can decide to block these visits. Let's say that "evil.ru" links to my site example.com?fake_parameter=porn then I want to block "evil.ru".

Add an address per line in the Referers List section.
Google in the "Search Console" tool provides the list of links pointing to your site.