They can use your wifi signal as a beacon by triangulating the signal strength from at least 3 different points. Then they can figure out in which departments you spend the most time, how long you spend in store, heatmaps, which aisles you skip and generic info like what time you visit, which locations you also shop at.
A quick google for "Retail Wifi tracking" brings up mirame.net , where you can see some of the features.
I would suggest to set your phone to flight mode if you see a "free wifi" sign in your shopping mall.
Because the people or companies they report on still use the platform :(