The SNP leader was warned his call for price caps on essential items could lead to "shortages" in shops.