If Israel decides to occupy the Gaza Strip and eliminate Hamas, as Netanyahu announced, there will be very heavy casualties on both sides.
In theory, Israel could destroy it through a prolonged siege, cutting off access to food, medicine and electricity, and force Hamas to capitulate with few casualties on the part of Israeli soldiers.
For sure this will be a heavy battle. They are doing Hamas a favor by destroying infrastructure. This is not Sovyet style architecture with the big, wide boulevards, symmetrical buildings and roads. This is middle eastern architecture with to many narrow streets and buildings basically glued to one another. If you start drilling holes trough the laws from the building in the beginning of a street to the other end you can continue moving under cover trough the whole distance. The same applies for Israeli forces too but there is something which the groups in Gaza have advantage over and this is the underground city they built.
The IDF probably think that by leveling the buildings this will make the operation easier. In fact the urban clashes in Turkiye in the period of 2015-2016 proved that destroyed buildings are one of the most dangerous places to be around. Nobody knows what kind of IED or ambush is waiting within the ruins. Another question is that after these building are destroyed the roads between them will be blocked causing serious difficulties for both armor and infantry to move around. The engineers will have to work 24/7, creating opportunities for attacks against stationary forces. There is no easy way around. In every case the IDF will take heavy casualties especially knowing their lack of proper force for such operation. They will be entering a crowded area with around 2 million hostile people.
The only logical way is total siege Assad style to the point where they are forced to capitulate as you say but it is also impossible as the smuggling routes on the border with Egypt will be working and flow of supplies and weapons will continue. I think that land operation in Gaza will be a total catastrophe for IDF. They will have limited success but will pay heavy price.
And just to remind all the readers that this is only the tactical realm of one area of operations which would be Gaza. We are not taking about the further complications on regional level.
Just to clarify:
I present you the newest addition to the strategic missile arsenal of the Houthis in Yemen.
Toufan (Based on the Iranian Ghadr ballistic missile)
Range: Rumored to be ~2000km (Tel Aviv in range)