Class D fire extinguishers are used at air bases in my country to put out plane fires since our fighter jets are made out of a magnesium alloy which can burn.
Also alkali metals is fun
It depends on how large, what temperature, and what type of metal. If there's enough latent heat in the quantity of metal to flash boil a significant fraction of the water, you're going to have a bad time. If you're literally dropping it in the ocean on the other hand, then you'll get a brief but impressive geyser and the fire will go out.
(Unless this is an alkali metal we're talking about. In that case you'll just get a "vigorous reaction" of a size proportional to the quantity of metal. Ex: https://www.youtube.com/watch?v=cc6W6SptLvU)
Factories have been leveled by water hitting molten aluminum. The Hackaday link below does a great job summarizing the dangers.
https://hackaday.com/2020/12/30/water-and-molten-aluminium-i...
Explosion links:
https://youtu.be/jvddrln900Q (last ~20 seconds)
Source: Used to work at a very large aluminum facility.
https://en.m.wikipedia.org/wiki/Ammonium_perchlorate_composi...
And that introduced the conversation about using the right extinguisher for the job!
Yup, this is why you never douse an oil fire (say in the kitchen) with water. The fire will erupt! Seen it happen live. Fortunately the damage wasn't bad. One third-degree burn.
Another effect is when the fire (and typically, the cooking vessel) are hot enough to vaporize the water. This rapid vaporization spreads oil droplets rapidly, allowing much more of the oil to burn at once. It can appear explosive, even though it's just rapidly-expanding steam spreading fine oil droplets.
https://www.youtube.com/watch?v=i20zvZ-3MMw
Note the initial dispersion of some atomized material followed by a triggered explosion some time later.
I doubt that, if it burned forever you could use it to heat water and spin a turbine and produce free power. If you meant “forever” as “a long time”, then sure :P
It would eventually cool down after removing the source of heat keeping the metal molten, which are electric resistive heating elements (assuming it works like an aluminum smelter).