This is generally only allowed if you are having an epidural or spinal and not general anesthesia. It may also not be allowed if you have an emergency situation. Your doctor, nurse or hospital administration can give you the specifics or when someone might not be allowed to stay with you. It may also depend on if you've been in labor or if this is a scheduled cesarean section.
Typically the person who will be attending the birth with you will be asked to wait in the hall outside the operating room for a few minutes before joining you. During this time you will have your body prepared for the birth, including draping your body, giving you oxygen, etc.
Some hospitals will allow you to have one person plus your doula. Though this varies from hospital to hospital and sometimes even depends on the doula.
Be sure to ask about the policies of a hospital when you take a hospital tour before giving birth.