Is there causality, behavioral or logical explanation behind this indicator or is it just purely an observation based on correlation? My guess is that there are existing derivatives with clauses that force them to take action that results in inverting the curve because it makes no sense to receive less for 10s than 3s.
When the market enters a risk-off period the investors proceed to a rotation between more risk assets (commodities, equities etc...) to the less risky ones. At this point there is just a lot of supply/demand imbalance on the bonds which drives the yield of the 10y down
When investors proceed to "flight to quality" they want to protect themselves against volatility which government debt offers however they do not necessarily want to get exposed to the long end of the curve (because they do not want to be exposed to long term inflation expectation moves) nor to the short end (because they do not want to be exposed to short term Fed policy changes). So this explains why in the end the demand tends to happen more in the "belly" of the curve (5->10y sector).
I have also heard it said (but never researched myself) that the reason it leads to recession is because when the yield curve inverts, banks prefer the higher yields they can get by investing their capital towards the lower end of the curve (instead of tying it up for longer and lower). In other words, bank lending on the long end drys up, and creates a drag on economic growth.
Your scepticism is warranted. Although there is correlation, the causality runs in reverse; When the market's get a wiff of the growth cycle peaking then this gets priced into the long end of the yield curve (as lower expectations of future growth and inflation pressure drives down expectations of poicy rate levels), causing inversion.