Ubuntu makes it fairly painless to switch to another window manager or desktop environment. Desktop environment refers to not only the window manager but also the suite of related applications, such as productivity or configuration tools.
First, you need to ensure that you have the relevant desktop environment installed on your system; the easiest way to do this is by installing the relevant
*-desktop package. You can do this by installing the package
kubuntu-desktop, for example (in the case of a KDE desktop); just search for “desktop” and look for Xubuntu or Kubuntu, and so on. After the download and installation is complete (you might want to grab a coffee while you wait because these packages include a ton of dependencies ...