Is this regulator a suitable replacement for original one?
The data sheet value for the thermal resistance between junction and "ambient" (when the tab is soldered to a 15 mm x 16 mm copper area of 1 oz/sq foot thickness) is 55 °C per watt of power dissipated: -



If you supply 20 volts to the regulator and it drops 16.7 volts in the process of producing 3.3 volts at the output, AND the output current is 300 mA, the power dissipated is about 4.9 watts.

This means that the device's "junction" (when mounted as per above) will heat up 55 x 4.9 °C above ambient i.e.,  in an ambient of 25 °C the junction will warm to 295 °C and this is clearly too much. You should also note that the local ambient will rise significantly above the average ambient under heavy dissipation situations.

So, you need either: -


A much bigger heat-sink area and/or thicker copper
A lower maximum continuous load current
A lower maximum ambient temperature
A fan targeted at the device
A switching regulator
A prayer