Redirect from within controller always goes to home page

I have a custom module named rsc. My Default 404 (not found) page is set to /page-not-found in Basic site settings. My rsc.routing.yml file contains rsc.pageNotFound: path: ‘/page-not-found’ defaults: _controller: ‘Drupal\rsc\Controller\rscController::pageNotFound’ _title: ” requirements: _permission: ‘access content’ My rscController.php file contains: class rscController extends ControllerBase { public function pageNotFound() { $path = ‘/test-page’; // Just…