Two ways:
- Process injection, requires skill in Reverse Engineering and some low level related knowledge
If you are a complete beginner and is just interested in making a bot, do not go for that solution, you'll spend a shitton of time doing the reverse engineering things but not focus on your bot architecture (which is, important if you want a good bot)
Second solution, through packets, it's about retro engineering, less IT knowledge required here.
You send the right packets that the servers expect you to send.
You should start learning how to write basic code (programming logic, loops, conditions...)
You should take a look to this project:

It's a good project and its API is beginner friendly.