I am faced with the task of creating a katra on which the directions of the routes will be visually displayed. For example, as on the map on this site.
Tell me, is it difficult to create such a map?
You do that with leaflet, https://leafletjs.com/
Not with osm
That site is quite a good example of “a map showing something”. There are basically three bits to it. There’s all the “non-map stuff” that make up the rest of the website, there’s the map itself (which has already been mentioned uses the Leaflet JS library) and there are the things displayed within that, in this case some background tiles (which actually use OpenStreetMap’s “OSM Carto” style, but could use any map style) and the airport squares and joining lines.
The only part of this map that is actually “OpenStreetMap” is actually the background tiles; all the rest is from elsewhere. There’s information about how to create tiles like that at https://switch2osm.org/manually-building-a-tile-server-18-04-lts/ . Another part of that site, https://switch2osm.org/using-tiles/getting-started-with-leaflet/ , says a little bit about overlaying things on top of a “Leaflet” map, but there are many, many more examples at https://leafletjs.com/examples.html .
Other completely different ways of making maps also exist - for just a couple of examples see https://openmaptiles.org/ and https://www.mapbox.com/maps/ .