See the docs on Docker Hub, it explains how to build Caddy with plugins.
Please also read How to use DNS provider modules in Caddy 2
Also, I recommend using Docker Compose instead of manual docker run
commands. See here: Keep Caddy Running — Caddy Documentation