Here's the RAM usage (and CPU) during the game:

And those are the tasks with most RAM usage during that time (game against easy AI just started)

And this is what it looks like after I ended CoH2

Restarting the game does not improve the situation - only a system restart can solve it. This problem is unique for CoH2 - I don't encounter anything like that with games such as Battlfield 4, Fallout 4, Witcher 3 etc.
It also seems like I can run those games without problems while this high RAM usage is in effect - something that doesn't count for CoH2 though.
What's the cause of this?