When you’re going to be doing penetration testing or hacking-related testing, it is necessary to build a lab because you cannot experiment on a live system. Therefore, you need a virtual environment, also known as a hypervisor . For Linux users, VirtualBox is a great solution; KVM is also good. For Windows, VMware Player is a good solution; Windows Virtual PC is also good, but you cannot run Linux distributions in it. For macOS, both QEMU and Parallels are good options.
For beginners, I suggest sticking to either VirtualBox or ...