From Walmart to Yonghui, brick-and-mortar retailers are developing private-label products as they fight for market share amid sluggish sales and weak profitability