To get to the Gradebook Setup page from the front page of your Moodle course, go to the Administration menu on the left and click Grades, and then click on Gradebook Setup in that menu. Everything discussed below starts on the Gradebook Setup page.
When you add activities such as Assignments or Quizzes to a Moodle course, corresponding grade items (columns) are added to the course gradebook. Moodle also lets you manually add grade items to your gradebook to record grades you may not have collected in Moodle, such as the grades for a midterm or for a project that was submitted offline. It allows you to define categories, for assignments that are similar in nature such as quizzes or homeworks. It's fine to build your gradebook as you go, but you should set up categories as early as possible, so that it is easier to sort your grade items so that they contribute to a final grade in the way that you want. For example, say a professor is going to base their final grade on these types of work:
Pre-class quizzes: 15%
Research paper: 30%
Final exam: 20%
This professor will want to define a category for pre-class quizzes and a category for homework, while the midterm, research paper, and final exam are single items.
You may already list what each type of work will contribute to the final grade, in your syllabus, and you can use this as a guide when setting up grade categories.