Are you talking about Yahoo webmail, or are you using an email program like Outlook Express on your computer, even though your account might be with a provider like Yahoo?
Yahoo Webmail
--------------------
If you are using Yahoo webmail, the message are taking up space on Yahoo's computers, not space on your computer. So don't worry about it unless you've had a message from Yahoo telling you your inbox is too full. I don't know know if there is a limit or what that limit is, but I have over 16,000 messages in my Yahoo inbox.
In Yahoo webmail, you can delete an email with an attachment. You can't delete the attachment and keep the email.
Just tick the box(es) next to the email(s) you want to delete, and click the delete button.
Or, open an email and click the delete button.
If your inbox is too full and you want to want to make space, a handy tip to click the heading at the top of the 'Size' column in the inbox. This will put the emails in order of size, allowing you to easily delete the largest ones.
You can also make some space by clicking on 'Empty' next to the Spam and Trash folders.
Email program on your computer
-----------------------------------------
I am using Microsoft Outlook 2010. It might be different for you if you have a different email program.
To delete an email, highlight it in the inbox view, and press the delete button on your keyboard.
To delete an attachment, open the email, right-click on the link to the attachment, and click on 'Remove attachment'.