The Windows package of Celestia is a self-extracting archive. Download it to your computer and then run it.
If you are running Debian or Ubuntu, see the instructions at the link below.
The macOS packages for versions 1.6.0 and 1.6.1 are disk image. Download one to your computer, double click it, and follow the instructions in the README. The package for 1.6.2 is a zipped bundle, download it and unpack.
Celestia is an open-source project. As such, its source code is provided and is freely modifiable and redistributable as per the GNU Public License. Installation instructions are provided in the INSTALL file.