Usually containers do not have a sshd running, therefore you should not attempt to connect to a container using putty.
Instead, list your containers:
docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
2570a852e4c1 ejabberd/ecs "/home/ejabberd/bin/…" 2 minutes ago Up 2 minutes 1883/tcp, 4369-4399/tcp, 5269/tcp, 5280/tcp, 5443/tcp, 0.0.0.0:5222->5222/tcp ejabberd
then use an interactive terminal(-it) to get inside the container and explore things:
docker exec -it 2570a852e4c1 sh
then check the contents of your file:
~ $ cat /home/ejabberd/conf/ejabberd.yml
###
### ejabberd configuration file
###
### The parameters used in this configuration file are explained at
###
### https://docs.ejabberd.im/admin/configuration
OR
Just execute the cat to see the content of the file, without even using an interactive terminal:
docker exec 2570a852e4c1 cat /home/ejabberd/conf/ejabberd.yml
According to your docker run command, you are mounting the ejabberd.yml file from your host's working directory(relative to where you're running the command) into the container at /home/ejabberd/conf/ejabberd.yml.
Changing this file inside the container will change the file on the host and vice-versa, therefore you can explore or write that config directly on the host.