what's wrong with just using
obj["a"] = 1;
obj["b"] = 2;
Print[obj["a"]]
or obj = { "a" -> 1, "b" -> 2 };
Print["a" /. obj]
?