A Dockerfile is a set of instructions about how a container for an application shall be built from the scratch using a base image. A docker-compose is a yaml script which comprises of how multiple docker containers grouped under a single subnet shall be built and run.
A docker-compose file runs on top of a Dockerfile and requires a path for the Dockerfile to be specified in the script for custom containers.