بسم الله الرحمن الرحيم
A mosque is meant for prayer and remembrance of Allah. It is not a place for worldly talk; hence one should not talk worldly things in the mosque. If someone sits in the mosque for worldly talks it is unlawful and sin. If someone comes in the mosque for prayer and by chance talks to some friends or his family or any businessman on mobile regarding the business then it is allowable and not haram provided his talk does not disturb anyone praying in the mosque. However, it is better to come out of mosque for short talk. It is proved from Sahabah and Salaf Salihin. Hadhrat Khalaf (رضى الله عنه) was sitting in the mosque, his slave came and asked in some worldly matter then he went out of the mosque and answered him.
كذا فى الدر والرد (2:436 ط مكتبة زكريا ديوبند) والفتاوى الهندية (5:321 ط مكتبة زكريا ديوبند) والبحر الرائق (2:63 ط مكتبة زكريا ديوبند) والأشباه والنظائر (ص 370-371 ط دارالكتب العلمية بيروت) ونفع المفتى والسائل (ص 53-54) وجواهر الفقه (آداب المساجد 3:115-116 مطبوعه مكتبه زكريا ديوبند) وفتاوى محموديه (جديد ڈابھیل 15: 197-200)
So, you can sometimes talk in short in the mosque with your family and business friend on phone it is not haram according to the preferred saying. However, if you come out of mosque then it is better. However, if your talk causes disturbance for those who are praying there then it is not lawful, it should be avoided.
Allah knows Best!
Darul Uloom Deoband