By default Ubuntu 18.04 doesn’t enable SSH, this post describes the steps you need to set up SSH.
Enabling SSH on Ubuntu 18.04
Since many people will not require a SSH daemon on their computer this is not enabled by default. This means if you want to SSH into your Ubuntu 18.04 machine you will need to enable SSH.
To enable this you will need to install the SSH daemon using apt. This can be down by entering the following command.
sudo apt install ssh
During the installation process, this will ask you to confirm the operations it is performing. Once the installation has completed the SSH server will be configured and accessible for anyone to use.
Now that it is installed you will be able to SSH into your machine from another.