You're missing the point in the text. One is only liable to get stoned if they did a certain set of actions in sacrificing to Molech.
That doesn't mean that one is permitted to worship Molech and get off on a technicality. If they ended up killing the child, then the penalty would be decapitation, which is considered a lesser form of punishment than stoning. The harsher sentence of stoning is only applied if they did all the actions associated with Molech.
MISHNA: And these are the transgressors who are killed by decapitation in the implementation of the court-imposed death penalty: The murderer; and the residents of an idolatrous city, all of whom engaged in idol worship. The mishna elaborates: In the case of a murderer who struck another with a stone or with iron, or held him in the water or in the fire, and the victim could not extricate himself from there and he died, the murderer is liable to be executed.
You're missing the point in the text. One is only liable to get stoned if they did a certain set of actions in sacrificing to Molech.
That doesn't mean that one is permitted to worship Molech and get off on a technicality. If they ended up killing the child, then the penalty would be decapitation, which is considered a lesser form of punishment than stoning. The harsher sentence of stoning is only applied if they did all the actions associated with Molech.
12 pages later on Sanhendrin 76b (https://www.sefaria.org/Sanhedrin.76b.9?lang=bi&with=Navigation&lang2=en):