Hi liche,
Others have mentioned using hotglue if you find the t-moulding will not stay in the slot.
That is a great idea but if you ever want to remove it again in the future then the hotglue will invariably take some timber with it, which might not be a good thing!
So instead of hotglue, I suggest you try folding some paper and sleeving it into the slot, then insert the t-moulding. The barbs on the t-moulding should press against the paper in the slot and it will all hold in place. If not, just remove it and put extra fold(s) in the paper to thicken it up a bit more then try again.
Just another suggestion!
ChrisW