Your daughter is copying someone, either her dad or someone at his house, or possibly something unsuitable on tv.
At 4 she is doing it to get a reaction. You have already told her calmly to stop. Now just ignore it. Don’t react, don’t look cross or upset, act as if it didn’t exist. She will soon get bored and move onto something new.
You could try distracting her, get her a children’s fun poems book and teach her one of those instead.