Yandex interview question

I was asked to write a shared_ptr implementation In algorithms section I was asked how hashmap allocates memory