There could be a lot of reasons that might be causing your laptop to freeze. The most prominent of all the causes might be:
1) Your storage  is full
2) Antivirus in your system
3) Faulty software
4) Heating up due to running a lot of programs together