Flue caps function to prevent rain from entering your stove pipe, and also to prevent changing wind conditions from creating a downdraft, forcing exhaust gases and smoke back into the boat's cabin.
In this latter function, there is a certain amount of "art" to their design, and you may have to try several styles if your installation suffers from repeated downdrafts.