Fix more folder mutation things (#53585)

Continuation of https://github.com/zed-industries/zed/pull/53566, now
with proper thread root mutation.

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Release Notes:

- N/A
857f81b04bMikayla Maki committed on 4/10/2026, 7:02:16 AM· committed by GitHubparent081081e
10 files changedLine totals unavailable