As shown by @MrKanister, when mapping volumes the path to the left of the colon is on your system. Everything to the right of the colon is inside the container. Unless you are a really advanced Docker user you will never need to change anything to the right of the colon.
So if you want to map a folder on your system called /mnt/joplin to where the Joplin Server data is located within the container (/var/lib/postgresql/data) then it would be:
/mnt/joplin:/var/lib/postgresql/data