If you’re curious where a command lives you can use which cmd or type cmd from the command-line and it will show you (something I often wish Windows had).
A command can ‘live’ in different places? And this might be a dumb question…but what is a command in this context?