Medium only allows for dofollow (meaning passes on link juice) to Medium.com domain links. Everything else as of 2019 was flagged as nofollow. I get why they did it as people were exploiting the high DR that Medium has for backlinks.
Alas, it also gutted the SEO of anyone who was publishing on a custom domain. If I link to myself, I either have to use a nofollow donnykimball.com link or I can use medium.com/@donnyjkimball to get a dofollow link.
The downside here is that if I ever moved off Medium doing the later, my entire SEO dies.