So I don't know if this is 100% technically correct but this is how I understand it as a customer that uses DMA.
DMA stands for direct memory access. You purchase a DMA device that usually slots into the m.2 or pci express slots of your gaming computer. The DMA device reads information about games or anything really that is stored in your computers memory and transmits it via a usb connection to another computer where cheat/hack software is ran. That software on the other computer reads the information from your gaming PC and can display things like enemy positions, item locations, and even in some cases make a crude aimbot by changing memory values in your gaming computer.
The devices are expensive and the setup is complicated. Here are some that I know are reputable:

Raptor DMA is another one that I think was made by DamnCheaters but i think they died.
Keep in mind these prices are for the DMA hardware devices only. You will need to buy subscriptions to the cheat software that uses it and in some cases may need to buy "firmware" to make the DMA device less likely to be detected.
ALSO, I highly recommend trying some of the software in small durations before you buy it. IMO Clutch-Solutions EFT software is the gold standard. Clutch's EFT DMA cheat is incredible. Some other products offered by Clutch and many other providers just aren't as good from what I have tried. You can do some pretty cool stuff with DMA but it seems like its a lot of work based on the limits of the technology. Some make some work arounds to display ESP on your gaming PC and its really clunky or significantly increases the detection rate. Games that are slower paced and can display a radar on the second PC seem to be the absolute best for DMA applications.