How can an imprisoned person establish prayer if he cannot find clean water or earth that is not clean enough to practise tayammum?
According to the opinion preferred by the Hanafis, a person who is imprisoned somewhere and cannot find water or something like clean earth to perform ablution or tayammum, imitates the actions of those who establish prayer out of respect to the prayer time, and establishes qada prayer when he is out of the prison (Kasani, Bada’i, I, 50; Haskafi, al- Durr al-Mukhtar, I, 184-185, 423). The opinion accepted as authentic in Shafi’i school is same as well (Nawawi, al-Majmu‘, II, 323). According to the Hanbali school, establishing qada prayer afterwards is not needed as they think that one may establish prayer in this situation (Ibn Qudamah, al-Mughni, I, 328).
Source: Presidency Of Religious Affairs The Turkey, High Board of Religious Affairs FATWAS