code: func checkVolumeSatisfyClaim(volume *v1.PersistentVolume, claim *v1.PersistentVolumeClaim) error {
  	requestedQty := claim.Spec.Resources.Requests[v1.ResourceName(v1.ResourceStorage)]
  	requestedSize := requestedQty.Value()
  
  	// check if PV's DeletionTimeStamp is set, if so, return error.
  	if utilfeature.DefaultFeatureGate.Enabled(features.StorageObjectInUseProtection) {
  		if volume.ObjectMeta.DeletionTimestamp != nil {
  			return fmt.Errorf("the volume is marked for deletion")
  		}
  	}
  
  	volumeQty := volume.Spec.Capacity[v1.ResourceStorage]
  	volumeSize := volumeQty.Value()
  	if volumeSize < requestedSize {
  		return fmt.Errorf("requested PV is too small")
  	}
  
  	requestedClass := v1helper.GetPersistentVolumeClaimClass(claim)
  	if v1helper.GetPersistentVolumeClass(volume) != requestedClass {
  		return fmt.Errorf("storageClassName does not match")
  	}
  
  	isMismatch, err := checkVolumeModeMismatches(&claim.Spec, &volume.Spec)
  	if err != nil {
  		return fmt.Errorf("error checking volumeMode: %v", err)
  	}
  	if isMismatch {
  		return fmt.Errorf("incompatible volumeMode")
  	}
  
  	if !checkAccessModes(claim, volume) {
  		return fmt.Errorf("incompatible accessMode")
  	}
  
  	return nil
  }
docs: // checkVolumeSatisfyClaim checks if the volume requested by the claim satisfies the requirements of the claim