Exactly this! If you are learning algorithms, you should be implementing your own trees rather than relying on a library like this that does the work for you.
The real benefit of learning algorithms comes when you put the hard work into it to build the data structures in a bottom up manner. Using someone else's tree generating library eliminates this experience which is a vital experience in the journey of learning algorithms.