In order to install KVM (Kernel-based Virtual Machine) in Ubuntu, you need to run just a few commands. Useful for your task could also be the article that is found at the Ubuntu community help page, but that is quite old and outdated. Nevertheless, here are the commands to run:
$ sudo apt install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils virt-manager
This will add about 600 MB of extra space to your hard-drive.
After the installation is done, you can run the command:
This will check the KVM installation. If everything went fine, you should see an output similar to this one:
INFO: /dev/kvm exists KVM acceleration can be used
Now, I will test the newly installed KVM in a GUI mode, but you can also use it in command line mode if you are running it inside a headless server, for example.
In the GUI mode, first you have to search for "Virtual Manager" inside the Activities area of Gnome. The icon of the Virtual Manager will appear and you will have to click on it to open the application. Now, for testing, I will install KDE neon inside a new KVM virtual machine. First, I will download the latest iso from neon.kde.org website and then I will use it to build the new VM.
Click on the "Create a new virtual machine" button on the left side of the window, below the menu bar, and then you will be prompted to create a new VM.
On step 1 you will select "Local Install Media" option, then click the forward button.
On step 2 you will browse for the iso file on your system.
On step 3 you will allocate the necessary amount of RAM and CPU's to the new VM.
On step 4 you will allocate the necessary amount of Hard Drive space for the new VM.
On step 5 you will name your new VM and start creating it.
After that, the VM will start and you can begin installing KDE neon 5.11.4.
Below is a image with the final VM using KDE Neon! Enjoy!