Question : How does the floppy drive write magnetic charges to a disk?

The floppy-disk controller : directs and controls reading from and writing to a computer's floppy disk drive. This controller is responsible for reading data presented from the host computer and converting it to the drive's on-disk format using one of a number of encoding schemes, such as FM encoding or MFM encoding, and reading those formats and returning it to its original binary values.

Question : What is FM encoding?

Frequency modulation encoding. The data is modified using differential Machester encoding

https://www.researchgate.net/publication/2984369_Runlength-Limited_Sequences

Bibligraphy from the above led to : https://en.wikipedia.org/wiki/Pulse-code_modulation

Led to https://en.wikipedia.org/wiki/Time-division_multiplexing

Led to https://en.wikipedia.org/wiki/%C3%89mile_Baudot