The value in a std::map can be any object that is copyable so you can have a map where the key and value are both std::string. e.g.
std::map<std::string, std::string>
but if you want to make the value generic, this is already handled as std::map is a template. But if you want an generic map where the key is always a string I think you have 2 options:
template <class T>
class StringMap : public std::map<std::string, T>
{
}
With this solution you will need to define the constructors.
or you could try (requires C++17):
using StringMap = std::map<std::string, std::any>;