Sure you can, for steganographic purposes. It doesnt mean it will get executed to, you would need a .jpg that exploits some image viewer vulnerability for that. Holes like that have existed in the past, and probably more exists that is yet to be found or is not yet public (aka 0-day)