How to sort view search results by giving custom relevance weights?
Drupal core's search can't really do this. You'll need to use something like the Search API contrib module (https://www.drupal.org/project/search_api).

Search API allows you to plug in different backends ("servers") for the search database. I have the most experience with Solr, rather than the "database" backend. Solr, for sure, lets you not only choose which fields get indexed, but also how much relevance each field is awarded when a search matches. That is, you can say to index the title of the node as a Fulltext, with a score (weight) of 5, but index the body as Fulltext with a weight of 4.