I think you'll want to know how the computer works with the code .
The exact way the operating system loads an executable is from the operating system. The executable format itself also depends.
Virtual memory
In modern OS there is a virtual memory system. When a command sends an executable, it normally maps the file to memory. So in a way it does not matter much what is in the mass storage system or in RAM. Of course it needs to be in RAM to run, but when the contents will go to the RAM is determined by the need and algorithms implemented in the operating system. The load is made on pages with 4KB (the most common) size.
Thevirtualaddressesareprovidedbytheoperatingsystem.Theactualaddressesareprovidedbytheprocessor.Everymodernhigh-capacityprocessorhasavirtualaddresstranslationsubsystemforphysicsthatdoesnotimposecostonnormalprocessing.
Allthiscanbestbeseenin another question here .
Transfer
The copy is made by another operating system service that interacts with the file system and driver which understands how to command the disk system or other form of "permanent" storage. Obviously it depends on the collaboration of the main processor or some secondary that controls the input and output devices and memory ( DMA ).
When the load is done it is possible to go handing the instructions to the processor.
Relocation
The load usually implies a hit of several addresses of global symbols. The code works with relative addresses. He does not quite know where he will actually be in the memory. Knowing relative addresses one can get the absolute of all symbols and the OS is responsible for relocating the addresses.
Uploading the executable
Of course, the executable does not just have instructions. There is a lot of information that helps the operating system decide how to work with it, which configures how it will need to work, among other things.
There is static data. The most common example is the text ( strings ) code present. But in fact virtually any literal will be in some form or by the instructions or in the static area.
There may also be data that is not accessed directly but is required by the application. Actually you can put anything in the executable:)
Before starting to run, a memory area is reserved for the stack and the heap begins to be formed, if necessary, almost always is. But this has more to do with the process as a whole, because each new thread will have its own stack .
Conclusion
Finally, this is simplicity. You can write a book about it. New specific questions can be asked.
If you want information about the electronic operation of the transfer, here is not the most appropriate place. If you want something more detailed, you would need to see what and where.
Addendum
The term assembler is often misused. It was not even there to use Assembler, nor Assembly . It's machine code itself.