I agree with you that this would be convenient but I suppose there could be a few motivations not to do this.
Issues from the user perspective:
Firstly in the case of the reply to the text message - This most likely has a monetary impact. Where I live, and I can only assume most other countries, text messages are charged for. The cost might be insignificant but the service provider cannot assume you have money to be able to reply on that text message.
In the case of the email - most of these emails are sent from addresses or through bulk mail providers that don't even allow replies on those emails (the motivation therefore partly security based I guess). This practice would obviously make it impossible to reply with a confirmation.
Issues from the service providers perspective:
If they allow users to respond via email or text message they need to parse those responses which could be a lot of work and consume very valuable computational resources. Anybody who has ever tried to parse responses in emails will know that headers get modified or lost and body contents can easily change,let alone character encoding issues giving you headaches. Same with test messages, although to a lesser extent. Those text message replies will have to be parsed and sanitized at the expense of the service provider.
Emails are trusted by users but are unfortunately inherently insecure. Please note I'm not saying all email is insecure but the amount of SMTP servers that do not employ some sort of transport layer security is shocking. It is also known that some very basic SMTP authentication protocols like CRAM-MD5 are not very secure. All this means that emails can easily be modified during transport by a MItM, making it extremely difficult for the service provider to trust those responses. They would much rather you get the code, copy it and go and paste it in a nice secure form on their HTTPS site - a lot less work for them. This is of course most relevant with high value and critical processes like a response to authorize a Bitcoin transaction from an online wallet.
What I have however seen from certain sites is an email with a link that points to a secure site with a query string at the end containing my reference number. Clicking on that link then posts to the secure site and submits your code. This works great if you assume that the link was not somehow altered.
I suppose the best solution would be to provide a range of choices since there are alternative options on how you would like to respond on that notification, but that would entail that the website do more work - which they don't always like.