Custom module is not working I created custom module to display Hello world text in custom page. I did not install drush and composer in my windows machine as I don't have admin access. I have pasted my files below:

example.module

&lt;?php

function example_menu() 
{
  // The paths given here need to match the ones in example.routing.yml exactly.
  $items['/mypage/page'] = array(
    'title' =&gt; 'First page',
    'description' =&gt; 'This is a example page.',
    // The name of the route from example.routing.yml
    'route' =&gt; 'example.my_page',
  );
  return $items;
}


example.routing

example.my_page:
  path: '/mypage/page'
  defaults:
    _controller: '\Drupal\example\Controller\ExampleController::mypage'
    _title: 'Hello world'
  requirements:
    _permission: 'access content'


src/Controller/ExampleController.php

&lt;?php

namespace Drupal\example\Controller;

//use Drupal\Core\Controller\ControllerBase;

class ExampleController 
{
    public function myPage() 
    {
        $element = array('#markup' =&gt; 'Hello world!');
        return $element;
    }
}


And I have example.info file as well and the module is enabled. When I run the controller, it says page not found. Can anyone tell me that Am I missed anything in the code?
hook_menu doesn't exist anymore in D8.
Instead use a example.links.menu.yml file.

example.my_page:
  title: 'First page'
  description: 'yout description'
  route_name: example.my_page