Questions on docs of `Borrow` trait

it has below sentences in the Borrow trait docs,

Beyond these generic wrappers that can be used with any type, some types provide optional facets providing potentially costly functionality. An example for such a type is String which adds the ability to extend a string to the basic str.

I do not understand why this is put in the context of Borrow trait. What costly functionality for String example? What use cases to avoid the costly functionality?