Only its pre-evolution, Munchlax, can learn Stockpile via level up in HeartGold/SoulSivler. Snorlax, unfortunately, cannot learn it in any way. You'll have to catch a Munchlax in another game, transfer it over, and train it to level 25. Evolve it, and you'll have a Snorlax with Stockpile.
You can breed for a Munchlax by giving the Snorlax you breed a Full Incense. (thanks for the correction ULQ)