I have modified your code please check the below code.
function add_octopus_child_option( $product_type_options ) {
$product_type_options['childocto'] = array(
'id' => '_childocto',
'wrapper_class' => 'show_if_octopus',
'label' => __( 'Gekoppeld', 'woocommerce' ),
'description' => __( 'Vink dit aan indien dit niet het hoofdproduct is.', 'woocommerce' ),
'default' => 'no'
);
return $product_type_options;
}
add_filter( 'product_type_options', 'add_octopus_child_option' );
function save_product_data_octopus($post_id){
$woocommerce_checkbox = isset( $_POST['_childocto'] ) ? 'yes' : 'no';
update_post_meta( $post_id, '_childocto', $woocommerce_checkbox );
}
add_action( 'woocommerce_process_product_meta_simple','save_product_data_octopus' );
add_action( 'woocommerce_process_product_meta_variable', 'save_product_data_octopus' );
Try with the above code and if does not work let me know.