Pass tree into `Builder::build`.

This allows the tree to be modified on running instance (will likely be
useful in testing scenarios for example).