code: def create_scan(self, scan_id='', targets='', options=None, vts=''):
          
  
          if self.data_manager is None:
              self.data_manager = multiprocessing.Manager()
  
          # Check if it is possible to resume task. To avoid to resume, the
          # scan must be deleted from the scans_table.
          if scan_id and self.id_exists(scan_id) and (
                  self.get_status(scan_id) == ScanStatus.STOPPED):
              return self.resume_scan(scan_id, options)
  
          if not options:
              options = dict()
          scan_info = self.data_manager.dict()
          scan_info['results'] = list()
          scan_info['finished_hosts'] = dict(
              [[target, []] for target, _, _ in targets])
          scan_info['progress'] = 0
          scan_info['target_progress'] = dict(
              [[target, {}] for target, _, _ in targets])
          scan_info['targets'] = targets
          scan_info['vts'] = vts
          scan_info['options'] = options
          scan_info['start_time'] = int(time.time())
          scan_info['end_time'] = "0"
          scan_info['status'] = ScanStatus.INIT
          if scan_id is None or scan_id == '':
              scan_id = str(uuid.uuid4())
          scan_info['scan_id'] = scan_id
          self.scans_table[scan_id] = scan_info
          return scan_id
docs: Creates a new scan with provided scan information.