Does the command systemctl and service exists on linux only and not mac?

The equivalent to Linux systemctl on macOS would be launchctl. Apache also has it's own HTTP Server Control Interface, apachectl.

OS X Man Pages