PS C:\Users\user\Desktop> docker login
Authenticating with existing credentials...
Login Succeeded
PS C:\Users\user\Desktop> docker push tree
The push refers to repository [docker.io/library/tree]
701ae319ce59: Preparing
1445d87cb5ce: Preparing
a9e822192dd4: Preparing
91ad130083b0: Preparing
096da3f810e4: Preparing
508c3f3b7a64: Waiting
7e453511681f: Waiting
b544d7bb9107: Waiting
baf481fca4b7: Waiting
3d3e92e98337: Waiting
8967306e673e: Waiting
9794a3b3ed45: Waiting
5f77a51ade6a: Waiting
e40d297cf5f8: Waiting
denied: requested access to the resource is denied
That is because you don't have push access to the docker.io/library/tree
repository. If you want to push an imge you created, to docker, you have to do it in your account, i.e. the push will be like
docker push <your-username>/tree