Syntax highlighting is a client side feature. All existing syntax highlighting tools outside custom implementations (like Visual Studio) use JS libraries that reformat your existing HTML code block with CSS classes.
AFAIK the code snippet in markdown doesn't support highlighting and only the devs could add that support. You should provide them feedback to request it. I believe there used to be a request for this but it is gone now. You can use the code editor block to get syntax highlighting though (Format option at bottom of message and then code snippet option). You'd use that in lieu of markdown.