How to alter a link of the language switcher?
To wrap this up, here is the complete solution to this problem.

function mytheme_preprocess_links__language_block(&amp;$variables) {
  $internal_path = $variables['links']['ja']['link']['#url']-&gt;getInternalPath();

  // In this case 'node/30074' is the translated node that will normally go to 
  if ($internal_path == 'node/30074') {

    // We need to create a new Url object with the node we need to redirect to
    $new_internal_path = Drupal\Core\Url::fromRoute('entity.node.canonical', ['node' =&gt; 30073], []);

    // ...and replace the original Url object  
    $variables['links']['ja']['link']['#url'] = $new_internal_path;
  }
}


Thanks to Clive for pointing out the process for this problem.