What is HAL_SPI_TransmitReceive purpose and how it works
SPI is a very specific interface and slave can only transmit if the master transmits. You have to transmit dummy data in order to receive something. 

So you cant send 4 bytes and receive 7. You will need send as much data as it is needed. 

On every byte sent by the master slave sends one byte too. If slave starts to send valuable data after 4 bytes received and you expect to receive 7 form the slave you need to send 11 bytes.