I am asked to restart my computer everytime F-secure blocks a malware. Any way to stop the software to ask me restart my computer?
Well, the best way is to get rid of malware on the system.
Most likely, a restart is required as F-Secure cannot clean up system (after removal) or remove malware. Perhaps this or that file (item) is occupied by some process. Or it is required to carry out certain procedures. Another point is if malware has been blocked or detected in a critical location. In this case, the reboot is probably one of the stages of restoring safe states.
Since you mentioned "blocked" - then perhaps this is some kind of specific item and since it is not automatically quarantined (and / or deleted), a reboot is required to attempt to delete or safely quarantine. For example, for preserving the possibility of restoring it from quarantine.
Perhaps there is no option as such to disable the reboot request. And there remains only the opportunity to eliminate the reason for the ask to restart computer. So, either delete the malicious items, or try to "exclude" the file or directory with the file from (real-time) scanning (but, perhaps, a manual scan will still detect it). Or to transfer detected items for re-analysis: Submit a sample | F-Secure
If you need help figuring out how to deal with malware. Or why the request for a reboot constantly appears (that is, the constant detection of something malicious) - then more information is required about your system, the name/place of the malware found, detection name and so on.
Otherwise, you could ask about ways to exclude files / directories. Alternatively, you can reach their official Support Channels for certified help. For example, web-chat: Contact support | F-Secure
By the way, there was a discussion about related subject:
Restart required. Restart required. Restart required — F-Secure Community
So, good if you will back with a feedback about your setting / situation / result.