A number of scholars have stated that it is makrooh to mention Allah verbally when having intercourse.
An-Nawawi (may Allah have mercy on him) said: it should be noted that dhikr (remembering Allah) is encouraged in all situations, except in situations referred to in shareeah, some of which we will mention here. For example: it is makrooh to remember Allah (verbally) when sitting to relieve oneself, when having intercourse, during the khutbah for the one who can hear the voice of the khateeb, when standing during the prayer, at which time one should be focusing on the recitation, and when one is drowsy.
End quote from al-Adhkaar, p. 12
Ibn Allaan said in his Sharh: what is meant by dhikr here is remembering Allah verbally, because this is what one is required to refrain from in the cases listed. As for remembering Him in one's heart, that is required even in these cases. Our companions said: if the one who is relieving himself or engaged in intercourse sneezes, he should praise Allah in his heart. In al-Haraz ath-Thameen it says that dhikr in one's heart at the time of relieving oneself or engaging in intercourse is not makrooh, according to scholarly consensus. As for remembering Allah verbally at those times, that is not something that is prescribed for us and the Prophet (blessings and peace of Allah be upon him) did not recommend it to us and it was not narrated from any of the Sahaabah. Rather at such times it is sufficient to be modest and remember that Allah is always watching, and remember the blessing that Allah, may He be exalted, has bestowed by making it easy to expel this harmful matter that, if it was not expelled, might kill one. This is one of the greatest forms of dhikr even if it is not spoken verbally.
End quote from al-Futoohaat ar-Rabbaaniyyah, 1/143
From this you may know that you can remember Allah in your heart, but it is makrooh to utter the dhikr out loud.
See: al-Mawsooah al-Fiqhiyyah, 21/247
See also the answer to questions no. 103871 and 135477
And Allah knows best.
Reproduced from Islam QA