Don't know how many there is or if the game looks for ports that have pens to be used for refit, but you can see if the port has uboat pen in it by simply zooming into it on the map.
Here's how the pen looks like on the map:
And yes, AFAIK, you must sail to the port. No teleporting.