The verse in question does not say that the sun sets in in a murky pool; rather, it says that Dhul-Qarnayn found it as if it were setting in a murky pool (this is what appeared to his eyes).
حَتَّىٰ إِذَا بَلَغَ مَغْرِبَ الشَّمْسِ وَجَدَهَا تَغْرُبُ فِي عَيْنٍ حَمِئَةٍ وَوَجَدَ عِندَهَا قَوْمًا ۗقُلْنَا يَا ذَا الْقَرْنَيْنِ إِمَّا أَن تُعَذِّبَ وَإِمَّا أَن تَتَّخِذَ فِيهِمْ حُسْنًا
Until, when he reached the setting of the sun, he found it [as if] setting in a spring of dark mud, and he found near it a people. Allah said, "O Dhul-Qarnayn, either you punish [them] or else adopt among them [a way of] goodness."
— Al-Kahf 18:86
Had it been setting in a murky pool, then Dhul-Qarnayn should have seen it rise out of the murky pool; rather, he sees it rising on people who were not shielded from it, on the other side of the planet as the verses say he had traveled across:
حَتَّىٰ إِذَا بَلَغَ مَطْلِعَ الشَّمْسِ وَجَدَهَا تَطْلُعُ عَلَىٰ قَوْمٍ لَّمْ نَجْعَل لَّهُم مِّن دُونِهَا سِتْرًا
Until, when he came to the rising of the sun, he found it rising on a people for whom We had not made against it any shield.
— Al-Kahf 18:90
Furthermore, while there are direct verses with no use of literary devices, as in An-Nisa' 4:17: "So believe in Allah and His messengers," one can find the use of literary devices as in As-Saffat 37:65: "Its emerging fruit as if it was heads of the devils."
Qur'an uses multiple literary devices from similes to metaphors to other devices that are commonly employed in the Arabic language (التصوير ـ التمثيل ـ الجدل ـ القصص), as in this example:
وَالَّذِينَ كَفَرُوا أَعْمَالُهُمْ كَسَرَابٍ بِقِيعَةٍ يَحْسَبُهُ الظَّمْآنُ مَاءً حَتَّىٰ إِذَا جَاءَهُ لَمْ يَجِدْهُ شَيْئًا وَوَجَدَ اللَّهَ عِندَهُ فَوَفَّاهُ حِسَابَهُ ۗ وَاللَّهُ سَرِيعُ الْحِسَابِ
But those who disbelieved — their deeds are like a mirage in a lowland which a thirsty one thinks is water until, when he comes to it, he finds it is nothing but finds Allah before Him, and He will pay him in full his due; and Allah is swift in account.
— An-Nur 24:39
Obviously this verse is using imagery to describe what happens to disbelievers on the day of judgment about what they perceive to be their good deeds.
Finally, the various tafsirs do not support the view that sun actually sets in a murky water; rather, this is how it was perceived from the view of Dhul-Qarnayn as he saw the sun sink in the lake or pool.
View in tafsirs
Here are quotes from different major tafsirs of this verse by authors over a number of centuries, and they point to the same concept. Translations are mostly my own, so treat with care.
وقوله: وجدها تغرب في عين حمئة أي: رأى الشمس في منظره تغرب في البحر المحيط وهذا شأن كل من انتهى إلى ساحله يراها كأنها تغرب فيه وهي لا تفارق الفلك الرابع الذي هي مثبتة فيه لا تفارقه
And His saying: "he found it setting in a spring of Hami'ah" meaning, he saw the sun as if it were setting in the ocean. This is something which everyone who goes to the coast can see: it looks as if the sun is setting into the sea, but it never leaves its path in the fourth orbit, in which it is fixed.
قال القفال قال بعض العلماء: ليس المراد أنه انتهى إلى الشمس مغربا ومشرقا وصل إلى جرمها ومسها ـ لأنها تدور مع السماء حول الأرض من غير أن تلتصق بالأرض، وهي أعظم من أن تدخل في عين من عيون الأرض، بل هي أكبر من الأرض أضعافا مضاعفة ـ بل المراد أنه انتهى إلى آخر العمارة من جهة المغرب ومن جهة المشرق، فوجدها في رأي العين تغرب في عين حمئة، كما أنا نشاهدها في الأرض الملساء كأنها تدخل في الأرض
Al-Qaffal said: "What is intended is not that he stopped when reaching the actual setting point and eastwards where it actually rises, and he reached its orbit and touched it — for the sun orbits around the earth without touching it, and it is larger in size to get into a well on Earth. It is way larger. What is intended that he reach the end of urban area to the west and east. He then found it in his own eyes as if it were setting in a murky pool, as we see on flat smooth land as if the sun is setting into Earth.
فأعطاه الله ما بلغ به مغرب الشمس حتى رأى الشمس في مرأى العين كأنها تغرب في عين حمئة أي: سوداء ـ وهذا هو المعتاد لمن كان بينه وبين أفق الشمس الغربي ماء، رآها تغرب في نفس الماء وإن كانت في غاية الارتفاع
Then Allah gave him the means to reach the sunset point, where he saw the sun in his eyes as if it were setting in a murky pool; murky being black. This is common for anyone who can see the sun set in the horizon; one sees set into the water, albeit it is very high up.
حتى إذا وصل ذو القرنين إلى مغرب الشمس وجدها في مرأى العين كأنها تغرب في عين حارة ذات طين أسود
Until Dhul-Qarnayn arrived at the point of sunset, and he found it in his eyes as if it is setting in murky pool with black mud.
حتى إذا بلغ مغرب الشمس موضع غروبها وجدها تغرب في عين حمئة ذات حمأة وهي الطين الأسود وغروبها في العين في رأي العين وإلا فهي أعظم من الدنيا
Until he reach the place of sunset where he found it setting in a murky pool, which is black mud, and it setting in a pool is in the eyes of the beholder, but it is greater in size than Earth.