Does it cost UPS?
Nothing runs while your inventory doesn't change. When it does, one quick pass tidies it up.
Why do some items stay in my inventory?
Items that carry data of their own (named caravans, armor with equipment, blueprints, items with their own inventory) and items that spoil are never moved into the pocket, because they would lose their contents or their freshness. They stay in your inventory no matter what the limit says.
Does it work with other inventory mods?
It only uses the game's own inventory events, so it should. If something misbehaves, tell me which mods you run.