Tom Hanks' Commander Ernest Krause is a fictional character. Did German U-boats taunt U.S. destroyers with radio messages? No. At several points in the film, a German U-boat uses Greyhound's transmitting frequency and broadcasts threatening messages over the ship's loudspeakers.
Did U-boats taunt over radio?
The taunting German broadcasts didn't happen
The German speaker broadcasts blood-curdling messages proclaiming certain doom over the ship's loudspeakers. While effective storytelling, these mind games are not based in history.
Did U-boats send messages to allied ships?
I've gone through every book I've had on the Battle of the Atlantic and I can't find a single reference to U-boat crews using TBS (or other VHF voice radios) to talk to Allied surface ships, although U-boats like U-524 were able to listen to Allied VHF voice transmissions by late 1942.