This is already a huge gambiarra in PHP. In C # it's even worse because it's a language that encourages you to sort everything out at compile time.
Almost always (about 99+%) that someone does this is actually wanting to use a array or an hash table (map, dictionary, associative array) p>
When it is not one of these things the person is wanting to do something wrong and has no concept of it or has some other mechanism that serves better.
One of these mechanisms would be the run-time build , which is rarely needed, and if it is, few people can do it safely.
It does not have a specific mechanism because it does not need to and why it should not exist in any language.