Fix and improve documentation

Fix missing documentation. Add examples how to index a tree.