Free tools to write non-linear dialogues, also for Unity:
Yarn Spinner и Twine.
Plugin to integrate Twine into Unity:
https://assetstore.unity.com/packages/tools/cradle-93606
Comparison of these tools and their work with Unity:
https://medium.com/@haikus_by_KN/authoring-interactive-narrative-in-twine-2-vs-ink-a-quick-and-dirty-comparison-using-examples-e695eb4dfc3e
https://medium.com/@haikus_by_KN/twine-2-vs-ink-a-quick-and-dirty-unity-integration-comparison-99fe1e4549d