Please do not try any self or un-professional advise. The Size and girth of the penis grossly changes from a flaccid state to an erect state on sexual arousal. in the normal state often the skin covers the glans completely and during erection it gets pull back. If you are being able to have intercourse and now finding it difficult to pull the skin forward to the original condition, then we have to consider two options.
A. Complete Inability to pull the skin forward after erection or intercourse.This would be an emergency condition. Please do not try any self measures and DO NOT PUT ANY TIGHT BANDAGES (this can compromise the blood circulation to the glans penis). This condition is medically known as paraphimosis. This is a fairly painful condition. Because the hole at the tip of the foreskin is small and the glans is like a cone, the skin can easily slip back from the tip to the base but the other way in reverse if often difficult leading to congestion and swelling. Here the trained doctor/surgeon/urologist first will examine you, assess and then release the tight ring of skin at the base ( it will be like a tight elastic band), once this is released then the skin will be able to be pulled forward to cover the glans. Often the professionals will advise circumcision (removal of the foreskin) at the same time under local anesthesia or general anesthesia. This condition can potentially be infected, so they would also give you a course of antbiotics. Once you are better, the wound is healed well, you would be able to have a normal life including sexual activities.
B. Partial Inability to pull the skin forward after erection or intercourse. Here the foreskin can be partially moved forward and backward but at the extermes it would not be possible and you will have pain. Again, the professionals will assess and offer you a circumcision to get rid of the foreskin an solve the problem.
Some people do not want the foreskin to be removed and are scared that it would affect their potency etc. This is not true because circumcision does not affect the libido and performance. If the person wants to retain the foreskin, then the surgeons or urologists offer a procedure called as dorsal slit under local/general anesthesia wherein the hole at the tip of the foreskin is extended like a key hole so that it can slide forward and backward.
Last but not least, recurrent infections in adult life in the foreskin can lead to this condition and it is often associated with diabetes mellitus. This condition is known as chronic balanoposthitis and the treatment is the same apart from checking and treating diabetes if detected.