If they dropped the device in the volcano, there would be no prime directive subplot, nor Spock disregarding the feelings of others subplot, which was the point of the entire sequence.
As for the in-universe reason, we arrived there mid-action, do we really want to sit there and watch all they did the entire night that forced them to proceed in this way? People have done much weirder things in the real world, that's not even puzzling. Why would experienced campers run out in the dead cold in their underwear and jump off trees to their deaths en masse? I have no idea, but it has happened. I am demanding an explanation for that before ruling the real world plausible.
Does it matter if Spock had to rest the device on a still hard surface outside of the lava after several unsuccessful attempts to drop it, or they discovered the automatic opener of the devices had malfunctioned because of a serial defect, or they were building the device right there and right then, and didn't expect the volcano to start erupting so soon and had to improvise, or Spock had just gone in Kirk-mode?
As for the in-universe reason, we arrived there mid-action, do we really want to sit there and watch all they did the entire night that forced them to proceed in this way? People have done much weirder things in the real world, that's not even puzzling. Why would experienced campers run out in the dead cold in their underwear and jump off trees to their deaths en masse? I have no idea, but it has happened. I am demanding an explanation for that before ruling the real world plausible.
Does it matter if Spock had to rest the device on a still hard surface outside of the lava after several unsuccessful attempts to drop it, or they discovered the automatic opener of the devices had malfunctioned because of a serial defect, or they were building the device right there and right then, and didn't expect the volcano to start erupting so soon and had to improvise, or Spock had just gone in Kirk-mode?