I know I can set a custom allocator for vectors using the syntax vector. Is there a way I can do the same for strings?
Yes. All string classes come from the class template basic_string, declared as such:
template ,
            class Allocator = allocator >
class basic_string;
  For example, std::string is just typedef basic_string.
The third template parameter is the allocator, so you can do something like:
typedef basic_string, my_allocator > my_string;