Mac OS is Unix - so it's basically up to you to decide where you want to install command line tools.
You will need to understand that the command line tools will use a 'search path' to look for the executable code for the commands issued in the Terminal or in scripts etc.
In Terminal…
echo $PATH
Will output something like… (this is NOT the default search path).
-> /bin:/sbin:/usr/X11/bin:/usr/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/ usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin
Which means the OS will look in each of those places for any command I run starting on the left (the colon is a separator). Bear in mind each user has their own search $PATH, this can be configured in the users profile (the ~/.bash_profile, ~/.bashrc and many other config files for other environments).
You can see where tools are installed via the 'which' command…
which echo ping
-> /bin/echo
-> /sbin/ping
Those locations are considered 'system' folders. In practice you will probably install into /usr/local/bin for any tools that you compile yourself. Compiled tools have arguments that can allow you to specify where it should be installed when you make the code.
Needless to say this is a complex thing to discuss, if you can be specific about what you hope to install that may help, otherwise we are left to point out vague generalities that may send you down the wrong path. What are you actually aiming to install & does it require compilation etc?
In general I'd avoid adding items to /bin, /sbin, /usr/bin, /usr/sbin , these are considered Apple's locations - software update will overwrite them. Stick with /usr/local as the location for third party tools.
Or you can create your own folder for commands/ scripts in your home folder & then add the path to the $PATH variable.
(Please excuse the lack of formatting - this forum is refusing access to the 'advanced editor' to make the code look cleaner).