In order to name organic compounds you must first memorize a few basic names. These names are listed within the discussion of naming alkanes. In general, the base part of the name reflects the number of carbons in what you have assigned to be the parent chain. The suffix of the name reflects the type(s) of functional group(s) present on (or within) the parent chain. Other groups which are attached to the parent chain are called substituents.
Check out this website for more info: https://www2.chemistry.msu.edu/faculty/reusch/VirtTxtJml/nomen1.htm220