Open /etc/apt/sources.list.d/docker.list and add the following content
deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable
Update and install
sudo apt-get update
If the process of sudo apt-get update is slow, you can try to use the domestic mirror
sudo apt-get install docker-ce