You can use a hash table which can be used to relate a value to a string key.
This way a string can be associated with a value. I think people are misunderstanding what you want to do. Perhaps you are creating your own interpreter ?
What it sounds like is that you want to add a new variable to the source code during runtime, which obviously doesn't make sense for a language like C++. How can this variable be referenced and used if the name can't be determined at compile time ? So perhaps you might want to rephrase the question with an example or is this what you mean ?