There are many ways to block or filter contents on MikroTik such as routing, DNS, Web Proxy and Firewall. But which method is correct to use, It base on what type of content you want to filter.
How about youtube, can you block base on IP address? Maybe not a good choice for you. If you block base on IP, it will effect to other google's services. Some people they use layer 7 and do filtering on firewall filter. But the problem is that all connection, the router try to check the layer 7 parttern. So it will consume alot of resource on your router.
I will block base on DNS query, so other packet beside DNS query will not check. And I mark the connection and use the connection mark to mark the packet. The result this rule will consume less CPU resource. Here is the rule that I created.
Mark the connection that match protocol UDP and destination port 53 with content=youtube.
/ip firewall mangle
add action="mark-connection" chain="prerouting" protocol=udp dst-port=53 connection-mark=no-mark content=youtube new-connection-mark=YOUTUBE_CONN passthrough=yes
Then use the connection mark to mark packet
add action=mark-packet chain="prerouting" connection-mark=YOUTUBE_CONN new-packet-mark=YOUTUBE_PACKET
Finally we start block the youtube packet via firewall filter
/ip firewall filter
add action=drop chain=forward packet-mark=YOUTUBE_PACKET
add action=drop chain=input packet-mark=YOUTUBE_PACKET
After done, you will not able to open youtube anymore. In case you still able to open youtube, you can try to clear history in your browser.