"Captain" (or its German equivalent "Kapitän") is not a protected title. Everybody and anybody can call themselves "Captain" for any reason or no reason under any circumstance without any type of license required.
It is, of course, possible to sign a contract that regulates how you are allowed to use that title within the context laid out in said contract. For example, many airlines uses the title "Kapitän" to refer a pilot who has achieved a certain rank within said airline. So, if an airline pilot who has not attained the rank of Kapitän calls themselves a "Kapitän" within the context of their employment as a pilot of said airline, then this might be a violation of their employment contract and thus they might face disciplinary action. But this is a private contractual matter between said pilot and said airline, not a law. [Note: I don't know what an actual airline employment contract looks like and whether airlines actually enforce this.]
If, OTOH, that same pilot rents a sailboat and takes the rudder, or plays football and is elected as the Kapitän of his team, or rides a tandem with a friend, they can refer to themselves as a "Kapitän", and any articles of their employment contract that would prohibit this would be void.