This is the easiest way to install docker and docker compose on debian.
Better yet docker updates can be done by rerunning the script mentioned or using apt upgrade etc
Assumes you followed Debian VM Install Instructions
Login as yourself
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
sudo systemctl enable docker
sudo systemctl start docker
No really thats it. Note the latest version of the script automatically installs the docker compose plugin. so no need to install python or old docker-compose python app.
if you do this on a pi based OS instead of debian you may need to also run
sudo usermod -aG docker pi
first