Where should I put it?
When installing a package, you can often choose which prefix to use. Most of the time, you should just leave this as the default. However, if you're curious then read on.
The prefix is similar to the installation path on Windows machines, in that it's the location in the filing system where the program files are placed. However, virtually all Linux software shares the same structure, which is standardised in the
Filesystem Hierarchy Standard, so often packages are combined together into the same directory. This has a number of advantages, namely a smaller path, and it's also useful in networked scenarios. A quick guide to prefixes:
/ - used for system software
/usr - used for user software that is available via a network
/usr/local - used for user software that is available locally, or installed by yourself
/opt - not used much, in theory meant for "optional" software. Most of the time, /usr/local is used instead.
If you're not on a network, then it doesn't really matter whether you use /usr/local or /usr.
Programs specific to a desktop environment such as KDE/GNOME are usually installed into the KDE/GNOME prefix if that isn't /usr or /usr/local (SuSE for instance places them in /opt/kde and /opt/gnome)
You should normally just accept the default, whatever that is. It's been chosen for you to minimize problems. Usually it'll be /usr or ~/.local.
You choose the prefix by passing the --prefix argument to a package, like this:
./foo.package --prefix=/opt