Stalin sent Mao a personal telegram asking him to enter the war. China went along most likely not inputting Stalin's request. China warned the UN about the need to protect national security.  China was soon involved with more than 1,350,000 troops, many had no weapons, but was to pick them up as they went. Numeral Chinese and North Korean offensives brought the war back near the 38th parallel.
From 1951-to 1953, fighting was at a stalemate, with few territorial changes. Leaders met to negotiate but combat and UN bombing continued. Negotiations stalled because many North Korean POWs did not want to be returned to the north.  A 1953 armistice established a new border almost exactly where the 38th parallel once stood as a temporary border.