How to reproduce:

```sql
VM-16-2-centos :) create table mem_test(a Int64, b Int64) engine = Memory

CREATE TABLE mem_test
(
    `a` Int64,
    `b` Int64
)
ENGINE = Memory

Query id: fb8d3ab7-6e69-410d-b5e3-9891c8604a9c

Ok.

0 rows in set. Elapsed: 0.004 sec. 
VM-16-2-centos :) set max_block_size = 3

SET max_block_size = 3

Query id: 6803f260-4893-4f0b-91cf-fc5d5670ce7c

Ok.

0 rows in set. Elapsed: 0.001 sec.

VM-16-2-centos :) insert into mem_test select number, number from numbers(100)

INSERT INTO mem_test SELECT
    number,
    number
FROM numbers(100)

Query id: 19f11e21-4b76-4015-ac05-99732facee6a

Ok.

0 rows in set. Elapsed: 0.002 sec.
VM-16-2-centos :) alter table mem_test update  a = 0 where b = 99

ALTER TABLE mem_test
    UPDATE a = 0 WHERE b = 99

Query id: a9d72960-7c86-4195-b739-7148fea99c10

Ok.

0 rows in set. Elapsed: 0.001 sec. 

VM-16-2-centos :) select * from mem_test format Null

SELECT *
FROM mem_test
FORMAT Null

Query id: 413f4d7e-cca9-4523-aedb-f9673bc515cb


0 rows in set. Elapsed: 0.011 sec. 

Received exception from server (version 21.6.1):
Code: 49. DB::Exception: Received from localhost:9000. DB::Exception: Invalid number of rows in Chunk column Int64 position 1: expected 1, got 3: While executing Memory. 


```
{
        size_t inserted_bytes = 0;
        size_t inserted_rows = 0;
        for (const auto & block : new_blocks)
        {
            inserted_bytes += block.allocatedBytes();
            inserted_rows += block.rows();
        }
        std::lock_guard lock(storage.mutex);
        auto new_data = std::make_unique<Blocks>(*(storage.data.get()));
        new_data->insert(new_data->end(), new_blocks.begin(), new_blocks.end());
        storage.data.set(std::move(new_data));
        storage.total_size_bytes.fetch_add(inserted_bytes, std::memory_order_relaxed);
        storage.total_size_rows.fetch_add(inserted_rows, std::memory_order_relaxed);
    }
private:
    Blocks new_blocks;
    StorageMemory & storage;
    StorageMetadataPtr metadata_snapshot;
};
StorageMemory::StorageMemory(