compiling in visual studio eats a ton of disk space

Hi, noob question but I am following an unreal engine C++ tutorial and when I added my first C++ actor class in UE 5.1 it told me to compile in vs so I did and it used up 10 GB for a single actor class file and then when I tried to open the project it told me that the project was generated on a different version and I will have to generate or something to use it so I did it eat like 20gb more, is it normal for ue5 to eat so much space for a single c++ file?