Port 22 is convention, not law
SSH defaults to port 22, but the daemon will happily listen on any port you tell it. Moving SSH off 22 is not real security — a port scan finds it in seconds — but on a public-facing server it dramatically reduces automated brute-force noise. A server on :22 sees thousands of attempts a day; on :2222 maybe a handful.
Connecting to a non-default port
The -p flag on the client side, the Port directive in ~/.ssh/config, or the -P flag on scp (yes, capital P — scp is annoyingly different).
Changing the server's port
Edit /etc/ssh/sshd_config, change Port 22 to your chosen number, restart sshd. If your firewall is filtering, open the new port and (later) close 22. Always keep an existing connection open as a lifeline.