Technically, it IS possible to create a dummy cartridge - but what you're really making is a blank. No, it will not cycle the slide though. Blanks typically are made by using a casing that is longer than a typically sized casing and crimped in such a way that the crimp actually forms the basic shape of a bullet. This makes it possible for them to feed in semi-automatic fashion. To get the gun to cycle though, blank-firing guns require a modification to constrict the gas flow so as to provide enough force to cycle the slide. Additionally, often the recoil spring will be replaced with a lighter one that will move with less force required.
This is essentially what you see with prop guns used in movies and on tv. Once a gun is modified to use a blank, it CANNOT use regular ammunition without being converted back to its original configuration.
Some guns, like ARs and AKs can function with blank ammunition with a simple device that attaches to the end of the barrel. Most other guns though require more significant modifications and entire businesses exist just making blank firing weapons, maintaining them, and manufacturing blanks for them.
Under NO condition is a blank to be used in self-defense.
1) To do so, you'd have to use a gun that could ONLY fire blanks. Or, manually cycle the slide after firing the blank.
2) Legally, you shouldn't be firing a weapon unless you intend for a projectile to hit your target. Warning shots are an often discussed topic and the consensus is that they are a horrible idea all around. (trust me, it's been hashed out a zillion times on every gun forum online),
3) Even a blank can kill a person. There is no telling if the metallic cartridge will rupture causing a piece of metal to go flying at bullet-like speed. This is why in movies and tv, the actors rarely actually point the guns at each other, the magic of film/tv just makes it look like they do. If you think a film executive is going to let a potentially lethal weapon be pointed at a star, think again. They have already learned their lesson. Look up "Brandon Lee" on Google for more info. Mistakes are made, and blanks are not guaranteed not to cause injury.
4) This is easily done with revolvers, but see the above reasons for why you should still not do it.
5) If pointing a gun at somebody to fire a blank, don't expect them to know it's a blank! To them, you've just presented a credible threat of death and/or severe bodily harm and they have just gained the right to point a gun at you with REAL ammunition and pull the trigger.
If after all this, you are still comprehending the idea, I don't know what to tell you.... it's a bad idea. It's good to see you're thinking about possibilities, and don't let this put you off from coming up with other ideas, but as you can see, bouncing ideas off the community can often show you a side of something you hadn't thought of and can potentially save your butt. In this case, it's well established that using blanks in self-defense is a bad idea and a good way to either end up in jail or more likely - dead.
Here at THR, we'd rather you avoid both.
Most of us here deal with having less-lethal force available in addition to lethal force. Pepper-spray, stun-guns, etc. are all good ways to defend yourself when force is warranted, but not deadly force.
If you tell us what state you're in, somebody might be able to recommend a book that will help you familiarize yourself with the relevant laws. This is EXTREMELY helpful.