[COREVM-87] Refactor `dynamic_object_container` into `object_container`

Currently `dynamic_object_container` defined in `include/dyobj/dynamic_object_container.h` is very tied up to the dynamic object layer. However, its purpose and functionality is very generic, and can be refactored into a standalone generic object container.

Let's rename it to `object_container` and move it to `include/memory/object_container.h`, and add an optional allocator type template argument.