They don't. https://www.fastfoodmenuprices.com/mcdonalds-prices/ In New Hampshire, a 10pc Mcnuggets is listed at $5.43, a 20pc at $6.05 and a 40pc at $10.88. This price curve is in line with fast food soda, whereby there's a base price and then small value adds to get you to buy more than you need. The actual cost of the food itself is a small component of the price of the item (consider: 10pc mcnuggets meal is $1.40 more than just the mcnuggets, which means you get a drink and fries for less than the fries cost by themself). The 40pc is clearly a party/family option where it's just enough cheaper that you'll buy a 40pc for less than a 20pc and a 10pc.
Perhaps this article would be more accurately titled, "Why Did 10 Chicken Nuggets Cost the Same as 20 in the Year 2015?" With that being said, maybe the pricing was just a fluke - a special - or some other attempt at playing with market behavior not touched on in the article. Maybe there was a chicken-parts surplus, or McD's managed to find several tons cut-rate from China.